aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/controllers/api/videos/index.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2019-01-15 14:52:33 +0100
committerChocobozzz <me@florianbigard.com>2019-01-15 14:59:40 +0100
commit1e7eb25f6cb6893db8f99ff40ef0509aa2a16614 (patch)
tree798937b32d894a3e1235e34398876ed875c1b72e /server/controllers/api/videos/index.ts
parent848f499def54db2dd36437ef0dfb74dd5041c23b (diff)
downloadPeerTube-1e7eb25f6cb6893db8f99ff40ef0509aa2a16614.tar.gz
PeerTube-1e7eb25f6cb6893db8f99ff40ef0509aa2a16614.tar.zst
PeerTube-1e7eb25f6cb6893db8f99ff40ef0509aa2a16614.zip
Correctly send Flag/Dislike/View activities
Diffstat (limited to 'server/controllers/api/videos/index.ts')
-rw-r--r--server/controllers/api/videos/index.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/controllers/api/videos/index.ts b/server/controllers/api/videos/index.ts
index 2b2dfa7ca..8414ca42c 100644
--- a/server/controllers/api/videos/index.ts
+++ b/server/controllers/api/videos/index.ts
@@ -23,7 +23,6 @@ import {
23 fetchRemoteVideoDescription, 23 fetchRemoteVideoDescription,
24 getVideoActivityPubUrl 24 getVideoActivityPubUrl
25} from '../../../lib/activitypub' 25} from '../../../lib/activitypub'
26import { sendCreateView } from '../../../lib/activitypub/send'
27import { JobQueue } from '../../../lib/job-queue' 26import { JobQueue } from '../../../lib/job-queue'
28import { Redis } from '../../../lib/redis' 27import { Redis } from '../../../lib/redis'
29import { 28import {
@@ -59,6 +58,7 @@ import { resetSequelizeInstance } from '../../../helpers/database-utils'
59import { move } from 'fs-extra' 58import { move } from 'fs-extra'
60import { watchingRouter } from './watching' 59import { watchingRouter } from './watching'
61import { Notifier } from '../../../lib/notifier' 60import { Notifier } from '../../../lib/notifier'
61import { sendView } from '../../../lib/activitypub/send/send-view'
62 62
63const auditLogger = auditLoggerFactory('videos') 63const auditLogger = auditLoggerFactory('videos')
64const videosRouter = express.Router() 64const videosRouter = express.Router()
@@ -422,7 +422,7 @@ async function viewVideo (req: express.Request, res: express.Response) {
422 ]) 422 ])
423 423
424 const serverActor = await getServerActor() 424 const serverActor = await getServerActor()
425 await sendCreateView(serverActor, videoInstance, undefined) 425 await sendView(serverActor, videoInstance, undefined)
426 426
427 return res.status(204).end() 427 return res.status(204).end()
428} 428}