From: Chocobozzz Date: Mon, 11 May 2020 09:06:12 +0000 (+0200) Subject: Add unique key on actor preferredUsername X-Git-Tag: v2.2.0-rc.1~52 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=0f06c4de69e2a2af04da6447a4cc0f9f99b5f3d8;p=oweals%2Fpeertube.git Add unique key on actor preferredUsername --- diff --git a/server/models/activitypub/actor.ts b/server/models/activitypub/actor.ts index e547d2c0c..34bc91706 100644 --- a/server/models/activitypub/actor.ts +++ b/server/models/activitypub/actor.ts @@ -123,13 +123,13 @@ export const unusedActorAttributesForAPI = [ } } }, - // { - // fields: [ 'preferredUsername' ], - // unique: true, - // where: { - // serverId: null - // } - // }, + { + fields: [ 'preferredUsername' ], + unique: true, + where: { + serverId: null + } + }, { fields: [ 'inboxUrl', 'sharedInboxUrl' ] },