aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/account/account.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2021-10-27 14:37:04 +0200
committerChocobozzz <chocobozzz@cpy.re>2021-10-29 11:48:21 +0200
commit2760b454a761f6af3138b2fb5f34340772ab0d1e (patch)
tree2b3a2d81478f8b432eb54cce4caa5a760c494627 /server/models/account/account.ts
parente4611b54910d8e7f2b4f8a97ee2d9cc8e1054127 (diff)
downloadPeerTube-2760b454a761f6af3138b2fb5f34340772ab0d1e.tar.gz
PeerTube-2760b454a761f6af3138b2fb5f34340772ab0d1e.tar.zst
PeerTube-2760b454a761f6af3138b2fb5f34340772ab0d1e.zip
Deprecate filter video query
Introduce include and isLocal instead
Diffstat (limited to 'server/models/account/account.ts')
-rw-r--r--server/models/account/account.ts6
1 files changed, 3 insertions, 3 deletions
diff --git a/server/models/account/account.ts b/server/models/account/account.ts
index 37194a119..056ec6857 100644
--- a/server/models/account/account.ts
+++ b/server/models/account/account.ts
@@ -228,10 +228,10 @@ export class AccountModel extends Model<Partial<AttributesOnly<AccountModel>>> {
228 name: 'targetAccountId', 228 name: 'targetAccountId',
229 allowNull: false 229 allowNull: false
230 }, 230 },
231 as: 'BlockedAccounts', 231 as: 'BlockedBy',
232 onDelete: 'CASCADE' 232 onDelete: 'CASCADE'
233 }) 233 })
234 BlockedAccounts: AccountBlocklistModel[] 234 BlockedBy: AccountBlocklistModel[]
235 235
236 @BeforeDestroy 236 @BeforeDestroy
237 static async sendDeleteIfOwned (instance: AccountModel, options) { 237 static async sendDeleteIfOwned (instance: AccountModel, options) {
@@ -457,6 +457,6 @@ export class AccountModel extends Model<Partial<AttributesOnly<AccountModel>>> {
457 } 457 }
458 458
459 isBlocked () { 459 isBlocked () {
460 return this.BlockedAccounts && this.BlockedAccounts.length !== 0 460 return this.BlockedBy && this.BlockedBy.length !== 0
461 } 461 }
462} 462}