2017-12-14 10:38:41 -06:00
|
|
|
import { isActorFollowActivityValid } from './actor'
|
2017-11-20 02:43:39 -06:00
|
|
|
import { isBaseActivityValid } from './misc'
|
2017-11-23 07:19:55 -06:00
|
|
|
import { isDislikeActivityValid, isLikeActivityValid } from './rate'
|
2018-09-04 03:22:10 -05:00
|
|
|
import { isAnnounceActivityValid } from './announce'
|
2017-11-20 02:43:39 -06:00
|
|
|
|
2017-11-23 07:19:55 -06:00
|
|
|
function isUndoActivityValid (activity: any) {
|
2017-11-20 02:43:39 -06:00
|
|
|
return isBaseActivityValid(activity, 'Undo') &&
|
|
|
|
(
|
2017-12-14 10:38:41 -06:00
|
|
|
isActorFollowActivityValid(activity.object) ||
|
2017-11-23 07:19:55 -06:00
|
|
|
isLikeActivityValid(activity.object) ||
|
2018-09-04 03:22:10 -05:00
|
|
|
isDislikeActivityValid(activity.object) ||
|
|
|
|
isAnnounceActivityValid(activity.object)
|
2017-11-20 02:43:39 -06:00
|
|
|
)
|
|
|
|
}
|
|
|
|
|
|
|
|
export {
|
2017-11-23 07:19:55 -06:00
|
|
|
isUndoActivityValid
|
2017-11-20 02:43:39 -06:00
|
|
|
}
|