Prepare Dislike/Flag/View fixes
For now we Create these activities, but we should just send them directly. This fix handles correctly direct Dislikes/Flags/Views, we'll implement the sending correctly these activities in the next peertube version
This commit is contained in:
parent
44b9c0ba31
commit
848f499def
30 changed files with 330 additions and 755 deletions
|
@ -4,7 +4,7 @@ import * as url from 'url'
|
|||
import * as uuidv4 from 'uuid/v4'
|
||||
import { ActivityPubActor, ActivityPubActorType } from '../../../shared/models/activitypub'
|
||||
import { ActivityPubAttributedTo } from '../../../shared/models/activitypub/objects'
|
||||
import { checkUrlsSameHost, getAPUrl } from '../../helpers/activitypub'
|
||||
import { checkUrlsSameHost, getAPId } from '../../helpers/activitypub'
|
||||
import { isActorObjectValid, normalizeActor } from '../../helpers/custom-validators/activitypub/actor'
|
||||
import { isActivityPubUrlValid } from '../../helpers/custom-validators/activitypub/misc'
|
||||
import { retryTransactionWrapper, updateInstanceWithAnother } from '../../helpers/database-utils'
|
||||
|
@ -42,7 +42,7 @@ async function getOrCreateActorAndServerAndModel (
|
|||
recurseIfNeeded = true,
|
||||
updateCollections = false
|
||||
) {
|
||||
const actorUrl = getAPUrl(activityActor)
|
||||
const actorUrl = getAPId(activityActor)
|
||||
let created = false
|
||||
|
||||
let actor = await fetchActorByUrl(actorUrl, fetchType)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue