aboutsummaryrefslogtreecommitdiffhomepage
path: root/server
diff options
context:
space:
mode:
Diffstat (limited to 'server')
-rw-r--r--server/models/user/user.ts2
-rw-r--r--server/tests/api/users/users.ts2
2 files changed, 2 insertions, 2 deletions
diff --git a/server/models/user/user.ts b/server/models/user/user.ts
index 20696b1f4..069d7266e 100644
--- a/server/models/user/user.ts
+++ b/server/models/user/user.ts
@@ -958,7 +958,7 @@ export class UserModel extends Model<Partial<AttributesOnly<UserModel>>> {
958 } 958 }
959 959
960 toMeFormattedJSON (this: MMyUserFormattable): MyUser { 960 toMeFormattedJSON (this: MMyUserFormattable): MyUser {
961 const formatted = this.toFormattedJSON() 961 const formatted = this.toFormattedJSON({ withAdminFlags: true })
962 962
963 const specialPlaylists = this.Account.VideoPlaylists 963 const specialPlaylists = this.Account.VideoPlaylists
964 .map(p => ({ id: p.id, name: p.name, type: p.type })) 964 .map(p => ({ id: p.id, name: p.name, type: p.type }))
diff --git a/server/tests/api/users/users.ts b/server/tests/api/users/users.ts
index 1419ae820..318ff832a 100644
--- a/server/tests/api/users/users.ts
+++ b/server/tests/api/users/users.ts
@@ -290,7 +290,7 @@ describe('Test users', function () {
290 expect(user.account.description).to.be.null 290 expect(user.account.description).to.be.null
291 } 291 }
292 292
293 expect(userMe.adminFlags).to.be.undefined 293 expect(userMe.adminFlags).to.equal(UserAdminFlag.BYPASS_VIDEO_AUTO_BLACKLIST)
294 expect(userGet.adminFlags).to.equal(UserAdminFlag.BYPASS_VIDEO_AUTO_BLACKLIST) 294 expect(userGet.adminFlags).to.equal(UserAdminFlag.BYPASS_VIDEO_AUTO_BLACKLIST)
295 295
296 expect(userMe.specialPlaylists).to.have.lengthOf(1) 296 expect(userMe.specialPlaylists).to.have.lengthOf(1)