aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/helpers/activitypub.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/helpers/activitypub.ts')
-rw-r--r--server/helpers/activitypub.ts10
1 files changed, 5 insertions, 5 deletions
diff --git a/server/helpers/activitypub.ts b/server/helpers/activitypub.ts
index 1ea6422ca..43907b596 100644
--- a/server/helpers/activitypub.ts
+++ b/server/helpers/activitypub.ts
@@ -1,8 +1,8 @@
1import { Activity } from '../../shared/models/activitypub/activity' 1import { ResultList } from '../../shared/models'
2import { ResultList } from '../../shared/models/result-list.model' 2import { Activity } from '../../shared/models/activitypub'
3import { AccountInstance } from '../models/account/account-interface' 3import { ACTIVITY_PUB } from '../initializers'
4import { AccountModel } from '../models/account/account'
4import { signObject } from './peertube-crypto' 5import { signObject } from './peertube-crypto'
5import { ACTIVITY_PUB } from '../initializers/constants'
6 6
7function activityPubContextify <T> (data: T) { 7function activityPubContextify <T> (data: T) {
8 return Object.assign(data,{ 8 return Object.assign(data,{
@@ -71,7 +71,7 @@ function activityPubCollectionPagination (url: string, page: any, result: Result
71 return orderedCollectionPagination 71 return orderedCollectionPagination
72} 72}
73 73
74function buildSignedActivity (byAccount: AccountInstance, data: Object) { 74function buildSignedActivity (byAccount: AccountModel, data: Object) {
75 const activity = activityPubContextify(data) 75 const activity = activityPubContextify(data)
76 76
77 return signObject(byAccount, activity) as Promise<Activity> 77 return signObject(byAccount, activity) as Promise<Activity>