UNPKG
agenda-paper
Version:
latest (1.1.3)
rc (1.1.2-rc.1)
1.1.3
1.1.2
1.1.2-rc.1
1.1.1
1.1.0
1.0.7
1.0.2
1.0.0
Show your daily agenda on an ePaper display
github.com/eshaham/agenda-paper
eshaham/agenda-paper
agenda-paper
/
server
/
middlewares
/
general.middleware.ts
9 lines
(7 loc)
•
297 B
text/typescript
View Raw
1
2
3
4
5
6
7
8
9
import
{
Request
,
Response
,
NextFunction
}
from
'express'
;
import
{
APRequest
}
from
'../requests-types'
;
export
const
initializePayload
= (
) =>
(
req: Request, res: Response, next: NextFunction
) =>
{
const
apRequest = <
APRequest
>req; apRequest.
payload
= apRequest.
payload
|| {};
next
(); };