diff options
author | Chocobozzz <me@florianbigard.com> | 2018-09-04 10:22:10 +0200 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2018-09-04 10:49:53 +0200 |
commit | 5cf84858d49f4231cc4efec5e3132f17f65f6cf6 (patch) | |
tree | f1ff23476ff54c32c3fa34db79c11f242855d3b4 /server/helpers/custom-validators | |
parent | 0b74c74abe5a44e9f564ab6adb5177ab17d28e91 (diff) | |
download | PeerTube-5cf84858d49f4231cc4efec5e3132f17f65f6cf6.tar.gz PeerTube-5cf84858d49f4231cc4efec5e3132f17f65f6cf6.tar.zst PeerTube-5cf84858d49f4231cc4efec5e3132f17f65f6cf6.zip |
Add federation to ownership change
Diffstat (limited to 'server/helpers/custom-validators')
-rw-r--r-- | server/helpers/custom-validators/activitypub/undo.ts | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/server/helpers/custom-validators/activitypub/undo.ts b/server/helpers/custom-validators/activitypub/undo.ts index a2831b0bf..f50f224fa 100644 --- a/server/helpers/custom-validators/activitypub/undo.ts +++ b/server/helpers/custom-validators/activitypub/undo.ts | |||
@@ -1,13 +1,15 @@ | |||
1 | import { isActorFollowActivityValid } from './actor' | 1 | import { isActorFollowActivityValid } from './actor' |
2 | import { isBaseActivityValid } from './misc' | 2 | import { isBaseActivityValid } from './misc' |
3 | import { isDislikeActivityValid, isLikeActivityValid } from './rate' | 3 | import { isDislikeActivityValid, isLikeActivityValid } from './rate' |
4 | import { isAnnounceActivityValid } from './announce' | ||
4 | 5 | ||
5 | function isUndoActivityValid (activity: any) { | 6 | function isUndoActivityValid (activity: any) { |
6 | return isBaseActivityValid(activity, 'Undo') && | 7 | return isBaseActivityValid(activity, 'Undo') && |
7 | ( | 8 | ( |
8 | isActorFollowActivityValid(activity.object) || | 9 | isActorFollowActivityValid(activity.object) || |
9 | isLikeActivityValid(activity.object) || | 10 | isLikeActivityValid(activity.object) || |
10 | isDislikeActivityValid(activity.object) | 11 | isDislikeActivityValid(activity.object) || |
12 | isAnnounceActivityValid(activity.object) | ||
11 | ) | 13 | ) |
12 | } | 14 | } |
13 | 15 | ||