diff --git a/src/services/i/pin.ts b/src/services/i/pin.ts index a39cc1e597..142fc18511 100644 --- a/src/services/i/pin.ts +++ b/src/services/i/pin.ts @@ -26,7 +26,7 @@ export async function addPinned(user: IUser, noteId: mongo.ObjectID) { const pinnedNoteIds = user.pinnedNoteIds || []; - if (pinnedNoteIds.length > 5) { + if (pinnedNoteIds.length >= 5) { throw new Error('cannot pin more notes'); }