monkeeShark/src/remote/activitypub/renderer/update.ts
syuilo b9cb6d1c10 refactor: refactoring imports
将来ESMに移行しやすいように
Related: #7658

なんかmochaが起動しなくなってるけど理由不明
すぐ直したい
2021-08-19 18:33:41 +09:00

14 lines
404 B
TypeScript

import config from '@/config/index.js';
import { User } from '@/models/entities/user.js';
export default (object: any, user: { id: User['id'] }) => {
const activity = {
id: `${config.url}/users/${user.id}#updates/${new Date().getTime()}`,
actor: `${config.url}/users/${user.id}`,
type: 'Update',
to: [ 'https://www.w3.org/ns/activitystreams#Public' ],
object
} as any;
return activity;
};