mirror of
https://gitlab.com/bignutty/labscore.git
synced 2025-06-10 07:03:08 -04:00
resolves issue (ref p3oekndq)
This commit is contained in:
parent
a8af3d8603
commit
e2ea8f43b8
1 changed files with 6 additions and 4 deletions
|
@ -133,11 +133,14 @@ module.exports = {
|
|||
|
||||
if(Object.keys(res.data.platforms).length === 0) return await editOrReply(context, createEmbed("error", context, "No images available for this emoji."));
|
||||
|
||||
let currentPlatform = "discord";
|
||||
|
||||
if(!res.data.platforms[currentPlatform]) currentPlatform = Object.keys(res.data.platforms)[0]
|
||||
let currentPlatform;
|
||||
|
||||
if(!res.data.platforms["twitter"]) currentPlatform = Object.keys(res.data.platforms)[0]
|
||||
else currentPlatform = "twitter"
|
||||
|
||||
// This handles selecting the correct "default" platform for enlarge.
|
||||
if(res.data.platforms["discord"]) currentPlatform = "discord"
|
||||
|
||||
// Use the high-res emojipedia icon, if available
|
||||
let ico = `https://raw.githubusercontent.com/jdecked/twemoji/main/assets/72x72/${toCodePoint(emoji[0])}.png`
|
||||
if(res.data.platforms["twitter"]) ico = res.data.platforms["twitter"].images[0].src
|
||||
|
@ -145,7 +148,6 @@ module.exports = {
|
|||
|
||||
const DEFAULT_PLATFORM = currentPlatform
|
||||
|
||||
|
||||
let currentView;
|
||||
let currentRevision = "";
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue