blob: 55b2801cad9bbb3c433196d716f66d10fad4a1e8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
import config from '../../../config';
import * as uuid from 'uuid';
export default (x: any) => {
if (x !== null && typeof x === 'object' && x.id == null) {
x.id = `${config.url}/${uuid.v4()}`;
}
return Object.assign({
'@context': [
'https://www.w3.org/ns/activitystreams',
'https://w3id.org/security/v1',
{ Hashtag: 'as:Hashtag' }
]
}, x);
};
|