aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/models/account/account.ts
diff options
context:
space:
mode:
authorChocobozzz <florian.bigard@gmail.com>2017-11-13 18:48:28 +0100
committerChocobozzz <florian.bigard@gmail.com>2017-11-27 19:40:51 +0100
commitce548a10db3822c415b30ea0edb59e02a460734a (patch)
treeb39127c62101b5bf47e0a8a3c30bc70d6449824d /server/models/account/account.ts
parent7a7724e66e4533523083e7336cd0d0c747c4a33b (diff)
downloadPeerTube-ce548a10db3822c415b30ea0edb59e02a460734a.tar.gz
PeerTube-ce548a10db3822c415b30ea0edb59e02a460734a.tar.zst
PeerTube-ce548a10db3822c415b30ea0edb59e02a460734a.zip
Send follow/accept
Diffstat (limited to 'server/models/account/account.ts')
-rw-r--r--server/models/account/account.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/server/models/account/account.ts b/server/models/account/account.ts
index daf8f4703..7ce97b2fd 100644
--- a/server/models/account/account.ts
+++ b/server/models/account/account.ts
@@ -198,6 +198,7 @@ export default function defineAccount (sequelize: Sequelize.Sequelize, DataTypes
198 loadApplication, 198 loadApplication,
199 load, 199 load,
200 loadByUUID, 200 loadByUUID,
201 loadByUrl,
201 loadLocalAccountByNameAndPod, 202 loadLocalAccountByNameAndPod,
202 listOwned, 203 listOwned,
203 listFollowerUrlsForApi, 204 listFollowerUrlsForApi,
@@ -480,11 +481,12 @@ loadLocalAccountByNameAndPod = function (name: string, host: string) {
480 return Account.findOne(query) 481 return Account.findOne(query)
481} 482}
482 483
483loadByUrl = function (url: string) { 484loadByUrl = function (url: string, transaction?: Sequelize.Transaction) {
484 const query: Sequelize.FindOptions<AccountAttributes> = { 485 const query: Sequelize.FindOptions<AccountAttributes> = {
485 where: { 486 where: {
486 url 487 url
487 } 488 },
489 transaction
488 } 490 }
489 491
490 return Account.findOne(query) 492 return Account.findOne(query)