mirror of
https://github.com/chylex/Discord-History-Tracker.git
synced 2025-04-13 07:17:12 +03:00
Fix attempting to store non-string embed descriptions
This commit is contained in:
parent
01376a1958
commit
3c363fef23
@ -184,10 +184,10 @@ class SAVEFILE{
|
||||
};
|
||||
|
||||
if (embed.type === "rich"){
|
||||
if (Array.isArray(embed.title) && embed.title.length === 1){
|
||||
if (Array.isArray(embed.title) && embed.title.length === 1 && typeof embed.title[0] === "string"){
|
||||
conv.t = embed.title[0];
|
||||
|
||||
if (Array.isArray(embed.description) && embed.description.length === 1){
|
||||
if (Array.isArray(embed.description) && embed.description.length === 1 && typeof embed.description[0] === "string"){
|
||||
conv.d = embed.description[0];
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user