mirror of
				https://gitlab.com/Kwoth/nadekobot.git
				synced 2025-11-04 08:34:27 -05:00 
			
		
		
		
	Fixed an issue with embed array not building if the color is invalid or unspecified
This commit is contained in:
		@@ -20,7 +20,10 @@ public sealed record SmartEmbedArrayElementText : SmartEmbedTextBase
 | 
			
		||||
    protected override EmbedBuilder GetEmbedInternal()
 | 
			
		||||
    {
 | 
			
		||||
        var embed = base.GetEmbedInternal();
 | 
			
		||||
        return embed.WithColor(Rgba32.ParseHex(Color).ToDiscordColor());
 | 
			
		||||
        if (Rgba32.TryParseHex(Color, out var color))
 | 
			
		||||
            return embed.WithColor(color.ToDiscordColor());
 | 
			
		||||
 | 
			
		||||
        return embed;
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user