Upgrade server dependencies
This commit is contained in:
parent
228e84aa7e
commit
ee28cdf1c4
5 changed files with 224 additions and 170 deletions
|
@ -19,7 +19,7 @@ inboxRouter.post('/inbox',
|
|||
inboxRouter.post('/accounts/:name/inbox',
|
||||
signatureValidator,
|
||||
asyncMiddleware(checkSignature),
|
||||
localAccountValidator,
|
||||
asyncMiddleware(localAccountValidator),
|
||||
asyncMiddleware(activityPubValidator),
|
||||
asyncMiddleware(inboxController)
|
||||
)
|
||||
|
@ -36,6 +36,8 @@ async function inboxController (req: express.Request, res: express.Response, nex
|
|||
const rootActivity: RootActivity = req.body
|
||||
let activities: Activity[] = []
|
||||
|
||||
console.log(rootActivity)
|
||||
|
||||
if ([ 'Collection', 'CollectionPage' ].indexOf(rootActivity.type) !== -1) {
|
||||
activities = (rootActivity as ActivityPubCollection).items
|
||||
} else if ([ 'OrderedCollection', 'OrderedCollectionPage' ].indexOf(rootActivity.type) !== -1) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue