diff options
Diffstat (limited to 'src/server/activitypub/featured.ts')
| -rw-r--r-- | src/server/activitypub/featured.ts | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/server/activitypub/featured.ts b/src/server/activitypub/featured.ts index 80a7852f59..66ad2aa86e 100644 --- a/src/server/activitypub/featured.ts +++ b/src/server/activitypub/featured.ts @@ -5,7 +5,6 @@ import renderOrderedCollection from '../../remote/activitypub/renderer/ordered-c import { setResponseType } from '../activitypub'; import renderNote from '../../remote/activitypub/renderer/note'; import { Users, Notes, UserNotePinings } from '../../models'; -import { ensure } from '../../prelude/ensure'; export default async (ctx: Router.RouterContext) => { const userId = ctx.params.user; @@ -27,7 +26,7 @@ export default async (ctx: Router.RouterContext) => { }); const pinnedNotes = await Promise.all(pinings.map(pining => - Notes.findOne(pining.noteId).then(ensure))); + Notes.findOneOrFail(pining.noteId))); const renderedNotes = await Promise.all(pinnedNotes.map(note => renderNote(note))); |