mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-12-24 16:13:08 +02:00
feat(server): add more metadata for emoji export
This commit is contained in:
parent
1bd7c55c88
commit
7a999f2289
1 changed files with 2 additions and 1 deletions
|
@ -11,6 +11,7 @@ import * as dateFormat from 'dateformat';
|
||||||
import { Users, Emojis } from '@/models/index';
|
import { Users, Emojis } from '@/models/index';
|
||||||
import { } from '@/queue/types';
|
import { } from '@/queue/types';
|
||||||
import { downloadUrl } from '@/misc/download-url';
|
import { downloadUrl } from '@/misc/download-url';
|
||||||
|
import config from '@/config/index';
|
||||||
|
|
||||||
const logger = queueLogger.createSubLogger('export-custom-emojis');
|
const logger = queueLogger.createSubLogger('export-custom-emojis');
|
||||||
|
|
||||||
|
@ -52,7 +53,7 @@ export async function exportCustomEmojis(job: Bull.Job, done: () => void): Promi
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
await writeMeta(`{"metaVersion":2,"emojis":[`);
|
await writeMeta(`{"metaVersion":2,"host":"${config.host}","exportedAt":"${new Date().toString()}","emojis":[`);
|
||||||
|
|
||||||
const customEmojis = await Emojis.find({
|
const customEmojis = await Emojis.find({
|
||||||
where: {
|
where: {
|
||||||
|
|
Loading…
Reference in a new issue