monkeeShark/src/remote/activitypub/act/create.ts

10 lines
251 B
TypeScript
Raw Normal View History

2018-03-31 10:55:00 +00:00
import create from '../create';
2018-04-02 08:11:14 +00:00
export default (resolver, actor, activity, distribute) => {
2018-03-31 10:55:00 +00:00
if ('actor' in activity && actor.account.uri !== activity.actor) {
2018-04-01 12:24:25 +00:00
throw new Error();
2018-03-31 10:55:00 +00:00
}
2018-04-02 08:11:14 +00:00
return create(resolver, actor, activity.object, distribute);
2018-03-31 10:55:00 +00:00
};