fix appinfo [ref 793y7tdls]

This commit is contained in:
derpystuff 2023-03-15 18:25:17 +01:00
parent 791a2349be
commit 5a93e8402d

View file

@ -115,7 +115,7 @@ module.exports = {
embed.fields.push({ embed.fields.push({
name: `${icon("rocket")} Embedded Activity`, name: `${icon("rocket")} Embedded Activity`,
value: content.join('\n'), value: content.join('\n').substr(0,1024),
inline: true inline: true
}) })
} }
@ -128,16 +128,17 @@ module.exports = {
embed.fields.push({ embed.fields.push({
name: `${icon("flag")} Flags`, name: `${icon("flag")} Flags`,
value: fl.join('\n'), value: fl.join('\n').substr(0,1024),
inline: true inline: true
}) })
} }
if(assets.length){ if(assets.length){
let asset = assets.map(a => link(`https://cdn.discordapp.com/app-assets/${application.id}/${a.id}.png?size=4096`, a.name)) let asset = assets.map(a => link(`https://cdn.discordapp.com/app-assets/${application.id}/${a.id}.png?size=4096`, a.name))
if(asset.length >= 6) asset[5] = link(`https://canary.discord.com/api/oauth2/applications/${application.id}/assets`, `View ${asset.length - 6} remaining assets`)
embed.fields.push({ embed.fields.push({
name: `${icon("image")} Assets`, name: `${icon("image")} Assets`,
value: '• ' + asset.join('\n• '), value: '• ' + asset.splice(0, 6).join('\n• ').substr(0, 1020),
inline: true inline: true
}) })
} }