Skip to content

Commit

Permalink
chore: fix cookie lifetime extend section in README.md
Browse files Browse the repository at this point in the history
Co-authored-by: Robin Simonklein <[email protected]>
  • Loading branch information
patrick-hofmann and robinsimonklein committed Nov 17, 2024
1 parent f8ce2ff commit d9a7d8e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -522,12 +522,12 @@ Example middleware:

```ts
// server/middleware/cookie-lifetime-extend.ts
export default defineEventHandler((event) => {
export default defineEventHandler(async (event) => {
const session = await getUserSession(event)
if (session && Object.keys(session).length > 0) {
await setUserSession(event, session)
}
}
})
```

## Server-Side Rendering
Expand Down

0 comments on commit d9a7d8e

Please sign in to comment.