2018-11-02 00:59:40 +01:00
|
|
|
import { IEmoji } from '../../../models/emoji';
|
|
|
|
import config from '../../../config';
|
|
|
|
|
|
|
|
export default (emoji: IEmoji) => ({
|
|
|
|
id: `${config.url}/emojis/${emoji.name}`,
|
|
|
|
type: 'Emoji',
|
|
|
|
name: `:${emoji.name}:`,
|
|
|
|
updated: emoji.updatedAt != null ? emoji.updatedAt.toISOString() : new Date().toISOString,
|
|
|
|
icon: {
|
|
|
|
type: 'Image',
|
2019-03-20 20:50:44 +01:00
|
|
|
mediaType: emoji.type || 'image/png',
|
2018-11-02 00:59:40 +01:00
|
|
|
url: emoji.url
|
|
|
|
}
|
|
|
|
});
|