[JSON] Add embed color (#403)

pull/405/head
Andrew Kolos 4 years ago committed by GitHub
parent 2a432c0ed2
commit c4007d4a80
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -1,4 +1,5 @@
using System.IO;
using System.Drawing;
using System.IO;
using System.Text.Json;
using System.Threading.Tasks;
using DiscordChatExporter.Domain.Discord.Models;
@ -114,6 +115,9 @@ namespace DiscordChatExporter.Domain.Exporting.Writers
_writer.WriteString("timestamp", embed.Timestamp);
_writer.WriteString("description", FormatMarkdown(embed.Description));
if (embed.Color != null)
_writer.WriteString("color", ColorTranslator.ToHtml(embed.Color.Value));
if (embed.Author != null)
await WriteEmbedAuthorAsync(embed.Author);

Loading…
Cancel
Save