mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 02:39:33 +02:00
Add follow tests
This commit is contained in:
parent
81de19482b
commit
0f91ae62df
23 changed files with 736 additions and 522 deletions
|
@ -6,7 +6,7 @@ import { logger } from '../../../helpers/logger'
|
|||
import { database as db } from '../../../initializers'
|
||||
import { AccountInstance } from '../../../models/account/account-interface'
|
||||
import { VideoChannelInstance } from '../../../models/video/video-channel-interface'
|
||||
import { getOrCreateAccount } from '../account'
|
||||
import { getOrCreateAccountAndServer } from '../account'
|
||||
import { getOrCreateVideoChannel } from '../video-channels'
|
||||
import { generateThumbnailFromUrl } from '../videos'
|
||||
import { videoActivityObjectToDBAttributes, videoFileActivityUrlToDBAttributes } from './misc'
|
||||
|
@ -14,7 +14,7 @@ import { videoActivityObjectToDBAttributes, videoFileActivityUrlToDBAttributes }
|
|||
async function processAddActivity (activity: ActivityAdd) {
|
||||
const activityObject = activity.object
|
||||
const activityType = activityObject.type
|
||||
const account = await getOrCreateAccount(activity.actor)
|
||||
const account = await getOrCreateAccountAndServer(activity.actor)
|
||||
|
||||
if (activityType === 'Video') {
|
||||
const videoChannelUrl = activity.target
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue