From cbc06a508d5b5324c5cbe9cb6e75790d3ef97f20 Mon Sep 17 00:00:00 2001 From: Matthew R Date: Tue, 14 Apr 2020 21:18:44 -0400 Subject: [PATCH] dynamically load emotes from configs/emotes.json --- src/class/Util.ts | 7 ++++--- src/configs/emotes.json | 14 ++++++++++++++ 2 files changed, 18 insertions(+), 3 deletions(-) create mode 100644 src/configs/emotes.json diff --git a/src/class/Util.ts b/src/class/Util.ts index d2d10f9..27ae07c 100644 --- a/src/class/Util.ts +++ b/src/class/Util.ts @@ -1,5 +1,6 @@ import { Member, Message, Guild } from 'eris'; import { Client, Command } from '.'; +import { statusMessages as emotes } from '../configs/emotes.json'; export default class Util { public client: Client; @@ -10,9 +11,9 @@ export default class Util { get emojis() { return { - SUCCESS: '<:modSuccess:578750988907970567>', - LOADING: '', - ERROR: '<:modError:578750737920688128>', + SUCCESS: emotes.success, + LOADING: emotes.loading, + ERROR: emotes.error, }; } diff --git a/src/configs/emotes.json b/src/configs/emotes.json new file mode 100644 index 0000000..3f0a0ab --- /dev/null +++ b/src/configs/emotes.json @@ -0,0 +1,14 @@ +{ + "whois": { + "titleAndDepartment": "<:loc:607695848612167700>", + "email": "<:email:699786452267040878>", + "gitlab": "<:gitlab:699788655748841492>", + "github": "<:github:699786469404835939>", + "bio": "<:bio:699786408193294416>" + }, + "statusMessages": { + "success": "<:modSuccess:578750988907970567>", + "loading": "", + "error": "<:modError:578750737920688128>" + } +}