utility.presence: null check custom status emotes try 2
This commit is contained in:
		
							parent
							
								
									cb4dee574d
								
							
						
					
					
						commit
						03feb6d3ae
					
				
					 1 changed files with 8 additions and 6 deletions
				
			
		| 
						 | 
				
			
			@ -728,13 +728,15 @@ presence.callback = async function (msg, line) {
 | 
			
		|||
      const activity = target.presence.activities[index];
 | 
			
		||||
      if (activity.type == 4) {
 | 
			
		||||
        let emote = "";
 | 
			
		||||
        if (activity.emoji?.id) {
 | 
			
		||||
        if (activity.emoji) {
 | 
			
		||||
          if (activity.emoji.id) {
 | 
			
		||||
            emote = `<${activity.emoji.animated ? "a" : ""}:${
 | 
			
		||||
              activity.emoji.name
 | 
			
		||||
            }:${activity.emoji.id}>`;
 | 
			
		||||
          } else {
 | 
			
		||||
            emote = activity.emoji.name;
 | 
			
		||||
          }
 | 
			
		||||
        }
 | 
			
		||||
 | 
			
		||||
        embeds.push({
 | 
			
		||||
          title: `${emote} ${activity.state}`,
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue