diff options
author | Chocobozzz <me@florianbigard.com> | 2022-08-08 15:48:17 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2022-08-09 09:18:07 +0200 |
commit | bd911b54b555b11df7e9849cf92d358bccfecf6e (patch) | |
tree | 23e94b4acbe6819fedc1cb5e067b700cbdd880c3 /server/lib/activitypub/actors | |
parent | 5a921e7b74910414626bfc9672b857e987e3ebed (diff) | |
download | PeerTube-bd911b54b555b11df7e9849cf92d358bccfecf6e.tar.gz PeerTube-bd911b54b555b11df7e9849cf92d358bccfecf6e.tar.zst PeerTube-bd911b54b555b11df7e9849cf92d358bccfecf6e.zip |
Use bullmq job dependency
Diffstat (limited to 'server/lib/activitypub/actors')
-rw-r--r-- | server/lib/activitypub/actors/get.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/lib/activitypub/actors/get.ts b/server/lib/activitypub/actors/get.ts index d2b651082..e73b7d707 100644 --- a/server/lib/activitypub/actors/get.ts +++ b/server/lib/activitypub/actors/get.ts | |||
@@ -110,7 +110,7 @@ async function loadActorFromDB (actorUrl: string, fetchType: ActorLoadByUrlType) | |||
110 | async function scheduleOutboxFetchIfNeeded (actor: MActor, created: boolean, refreshed: boolean, updateCollections: boolean) { | 110 | async function scheduleOutboxFetchIfNeeded (actor: MActor, created: boolean, refreshed: boolean, updateCollections: boolean) { |
111 | if ((created === true || refreshed === true) && updateCollections === true) { | 111 | if ((created === true || refreshed === true) && updateCollections === true) { |
112 | const payload = { uri: actor.outboxUrl, type: 'activity' as 'activity' } | 112 | const payload = { uri: actor.outboxUrl, type: 'activity' as 'activity' } |
113 | await JobQueue.Instance.createJobWithPromise({ type: 'activitypub-http-fetcher', payload }) | 113 | await JobQueue.Instance.createJob({ type: 'activitypub-http-fetcher', payload }) |
114 | } | 114 | } |
115 | } | 115 | } |
116 | 116 | ||
@@ -118,6 +118,6 @@ async function schedulePlaylistFetchIfNeeded (actor: MActorAccountId, created: b | |||
118 | // We created a new account: fetch the playlists | 118 | // We created a new account: fetch the playlists |
119 | if (created === true && actor.Account && accountPlaylistsUrl) { | 119 | if (created === true && actor.Account && accountPlaylistsUrl) { |
120 | const payload = { uri: accountPlaylistsUrl, type: 'account-playlists' as 'account-playlists' } | 120 | const payload = { uri: accountPlaylistsUrl, type: 'account-playlists' as 'account-playlists' } |
121 | await JobQueue.Instance.createJobWithPromise({ type: 'activitypub-http-fetcher', payload }) | 121 | await JobQueue.Instance.createJob({ type: 'activitypub-http-fetcher', payload }) |
122 | } | 122 | } |
123 | } | 123 | } |