File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -283,12 +283,28 @@ module.exports = {
283283 . setTimestamp ( ) ;
284284
285285 pageLicenses . forEach ( ( license , index ) => {
286- const status = license . status === 'active' ? '✅' : license . status === 'expired' ? '❌' : '⚠️' ;
286+ const rawStatus = String ( license . status || 'unknown' ) ;
287+ const normalizedStatus = rawStatus . toLowerCase ( ) ;
288+ let statusLabel = rawStatus . toUpperCase ( ) ;
289+ let statusIcon = '⚠️' ;
290+ if ( normalizedStatus === 'active' ) {
291+ statusLabel = 'ACTIVE' ;
292+ statusIcon = '✅' ;
293+ } else if ( normalizedStatus === 'expired' ) {
294+ statusLabel = 'EXPIRED' ;
295+ statusIcon = '❌' ;
296+ } else if ( normalizedStatus === 'revoked' ) {
297+ statusLabel = 'REVOKED' ;
298+ statusIcon = '🚫' ;
299+ } else if ( normalizedStatus === 'suspended' ) {
300+ statusLabel = 'SUSPENDED' ;
301+ statusIcon = '⛔' ;
302+ }
287303 const expires = license . expiresAt ? new Date ( license . expiresAt ) . toLocaleDateString ( ) : 'Never' ;
288304
289305 embed . addFields ( {
290- name : `${ status } ${ license . applicationName || 'Unknown App' } ` ,
291- value : `**Key:** \`${ license . key } \`\n**Plan:** ${ license . plan } \n**Expires:** ${ expires } ` ,
306+ name : `${ statusIcon } ${ license . applicationName || 'Unknown App' } ` ,
307+ value : `**Status:** ${ statusLabel } \n** Key:** \`${ license . key } \`\n**Plan:** ${ license . plan } \n**Expires:** ${ expires } ` ,
292308 inline : true
293309 } ) ;
294310 } ) ;
You can’t perform that action at this time.
0 commit comments