aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/activitypub
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-03-27 13:33:56 +0200
committerChocobozzz <me@florianbigard.com>2018-03-27 13:33:56 +0200
commit07197db4c567f22bbc9c12339062896dc76bac2f (patch)
tree5682f0d88fc1b4032018e5122ed42eb9967fd743 /server/controllers/activitypub
parentda99ccf2681bcbc172a96cf30e7b733948767faa (diff)
downloadPeerTube-07197db4c567f22bbc9c12339062896dc76bac2f.tar.gz
PeerTube-07197db4c567f22bbc9c12339062896dc76bac2f.tar.zst
PeerTube-07197db4c567f22bbc9c12339062896dc76bac2f.zip
Try to refractor activities sending
There is still a need for work on this part though
Diffstat (limited to 'server/controllers/activitypub')
-rw-r--r--server/controllers/activitypub/client.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/controllers/activitypub/client.ts b/server/controllers/activitypub/client.ts
index 347079816..8e295b4f9 100644
--- a/server/controllers/activitypub/client.ts
+++ b/server/controllers/activitypub/client.ts
@@ -4,7 +4,7 @@ import { VideoPrivacy } from '../../../shared/models/videos'
4import { activityPubCollectionPagination, activityPubContextify } from '../../helpers/activitypub' 4import { activityPubCollectionPagination, activityPubContextify } from '../../helpers/activitypub'
5import { pageToStartAndCount } from '../../helpers/core-utils' 5import { pageToStartAndCount } from '../../helpers/core-utils'
6import { ACTIVITY_PUB, CONFIG } from '../../initializers' 6import { ACTIVITY_PUB, CONFIG } from '../../initializers'
7import { buildVideoAnnounceToFollowers } from '../../lib/activitypub/send' 7import { buildVideoAnnounce } from '../../lib/activitypub/send'
8import { audiencify, getAudience } from '../../lib/activitypub/send/misc' 8import { audiencify, getAudience } from '../../lib/activitypub/send/misc'
9import { createActivityData } from '../../lib/activitypub/send/send-create' 9import { createActivityData } from '../../lib/activitypub/send/send-create'
10import { asyncMiddleware, executeIfActivityPub, localAccountValidator } from '../../middlewares' 10import { asyncMiddleware, executeIfActivityPub, localAccountValidator } from '../../middlewares'
@@ -130,7 +130,7 @@ async function videoController (req: express.Request, res: express.Response, nex
130 130
131async function videoAnnounceController (req: express.Request, res: express.Response, next: express.NextFunction) { 131async function videoAnnounceController (req: express.Request, res: express.Response, next: express.NextFunction) {
132 const share = res.locals.videoShare as VideoShareModel 132 const share = res.locals.videoShare as VideoShareModel
133 const object = await buildVideoAnnounceToFollowers(share.Actor, share, res.locals.video, undefined) 133 const object = await buildVideoAnnounce(share.Actor, share, res.locals.video, undefined)
134 134
135 return res.json(activityPubContextify(object)) 135 return res.json(activityPubContextify(object))
136} 136}