extra images now show on char tag add

master
Kit Kasune 3 years ago
parent 65d865560f
commit 10e0e5a454
  1. 26
      .idea/workspace.xml
  2. 20
      commands/anime/char.js

@ -4,8 +4,9 @@
<option name="autoReloadType" value="SELECTIVE" /> <option name="autoReloadType" value="SELECTIVE" />
</component> </component>
<component name="ChangeListManager"> <component name="ChangeListManager">
<list default="true" id="826c705b-a7fa-4ece-b82a-e278fca7d494" name="Changes" comment=""> <list default="true" id="826c705b-a7fa-4ece-b82a-e278fca7d494" name="Changes" comment="higher ani name for natsuki staff">
<change beforePath="$PROJECT_DIR$/.gitignore" beforeDir="false" afterPath="$PROJECT_DIR$/.gitignore" afterDir="false" /> <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/commands/anime/char.js" beforeDir="false" afterPath="$PROJECT_DIR$/commands/anime/char.js" afterDir="false" />
</list> </list>
<option name="SHOW_DIALOG" value="false" /> <option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" /> <option name="HIGHLIGHT_CONFLICTS" value="true" />
@ -23,6 +24,9 @@
<filtered-out-file-type name="COMMIT_BY_MESSAGE" /> <filtered-out-file-type name="COMMIT_BY_MESSAGE" />
</file-type-list> </file-type-list>
</component> </component>
<component name="MacroExpansionManager">
<option name="directoryName" value="4aelbj7e" />
</component>
<component name="MarkdownSettingsMigration"> <component name="MarkdownSettingsMigration">
<option name="stateVersion" value="1" /> <option name="stateVersion" value="1" />
</component> </component>
@ -94,9 +98,9 @@
<workItem from="1640131913922" duration="1135000" /> <workItem from="1640131913922" duration="1135000" />
<workItem from="1640142319793" duration="749000" /> <workItem from="1640142319793" duration="749000" />
<workItem from="1640147904557" duration="6966000" /> <workItem from="1640147904557" duration="6966000" />
<workItem from="1641528547432" duration="191000" /> <workItem from="1641588609694" duration="320000" />
<workItem from="1641707455657" duration="759000" /> <workItem from="1641840125341" duration="1415000" />
<workItem from="1641853758124" duration="2333000" /> <workItem from="1642537991410" duration="1236000" />
</task> </task>
<task id="LOCAL-00001" summary="not even gonna explain"> <task id="LOCAL-00001" summary="not even gonna explain">
<created>1640148826800</created> <created>1640148826800</created>
@ -126,14 +130,7 @@
<option name="project" value="LOCAL" /> <option name="project" value="LOCAL" />
<updated>1640214318896</updated> <updated>1640214318896</updated>
</task> </task>
<task id="LOCAL-00005" summary="fix images not showing in charsearch"> <option name="localTasksCounter" value="5" />
<created>1641863346127</created>
<option name="number" value="00005" />
<option name="presentableId" value="LOCAL-00005" />
<option name="project" value="LOCAL" />
<updated>1641863346127</updated>
</task>
<option name="localTasksCounter" value="6" />
<servers /> <servers />
</component> </component>
<component name="TypeScriptGeneratedFilesManager"> <component name="TypeScriptGeneratedFilesManager">
@ -157,7 +154,6 @@
<MESSAGE value="stoopid errors" /> <MESSAGE value="stoopid errors" />
<MESSAGE value="e" /> <MESSAGE value="e" />
<MESSAGE value="list characters in anime" /> <MESSAGE value="list characters in anime" />
<MESSAGE value="fix images not showing in charsearch" /> <option name="LAST_COMMIT_MESSAGE" value="list characters in anime" />
<option name="LAST_COMMIT_MESSAGE" value="fix images not showing in charsearch" />
</component> </component>
</project> </project>

@ -215,7 +215,25 @@ module.exports = {
aniData.markModified('characters'); aniData.markModified('characters');
aniData.save(); aniData.save();
} }
client.guilds.fetch('762707532417335296').then(g => g.channels.cache.get('932177797705781308').send({embeds: [amEmbed]})); client.guilds.fetch('762707532417335296')
.then(g => g.channels.cache.get('932177797705781308').send({embeds: [amEmbed]})
.then(nchm => {if (options.images && options.images.length) {
let imagesEmbed = new Discord.MessageEmbed()
.setAuthor({name: message.author.username, iconURL: message.author.avatarURL()})
.setTitle(`New Image ${queue ? "Submitted" : "Added"}`)
.setDescription(`For **${options.name}** | \`${options.id}\` from ${client.misc.cache.animeID.get(options.anime)}`)
.setThumbnail(options.thumbnail)
.setImage(options.images[0])
.setColor('c375f0')
.setTimestamp()
.setFooter({text: "Natsuki"})
if (options.images.length > 1) {imagesEmbed.addField("Images", options.images.join("\n"));}
nchm.guild.channels.cache.get('932177850239422494').send({
embeds: [imagesEmbed], content: queue ? '<@330547934951112705>' : undefined
}).catch(() => {});
}})
.catch(() => {})
);
am.delete().catch(() => {}); am.delete().catch(() => {});
return dmch.send(`Your character has been ${!queue ? "added" : "submitted"}`); return dmch.send(`Your character has been ${!queue ? "added" : "submitted"}`);
} else { } else {

Loading…
Cancel
Save