ani grammar stuff and haswatched toWatch list check

master
Kit Kasune 3 years ago
parent 5ef785fe3a
commit 8a6f82374f
  1. 3
      .idea/workspace.xml
  2. 2
      commands/anime/haswatched.js
  3. 2
      util/anime/anisearch.js

@ -5,8 +5,7 @@
</component>
<component name="ChangeListManager">
<list default="true" id="826c705b-a7fa-4ece-b82a-e278fca7d494" name="Changes" comment="more generous daily windows">
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/commands/leveling/daily.js" beforeDir="false" afterPath="$PROJECT_DIR$/commands/leveling/daily.js" afterDir="false" />
<change beforePath="$PROJECT_DIR$/commands/anime/haswatched.js" beforeDir="false" afterPath="$PROJECT_DIR$/commands/anime/haswatched.js" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />

@ -51,7 +51,7 @@ module.exports = {
} else {fn = asr.id;}
let ani = await AniData.findOne({id: fn});
let af = await AF.findOne({uid: user.id});
if (!af || !af.watched.includes(fn)) {return message.channel.send(`${user.id === message.author.id ? "You haven't" : "That person hasn't"} watched **${ani.name}**.`);}
if (!af || !af.watched.includes(fn)) {return message.channel.send(`${user.id === message.author.id ? "You haven't" : "That person hasn't"} watched **${ani.name}**${af && af.toWatch.includes(fn) ? `, *but* it is on ${user.id === message.author.id ? "your" : "their"} watch list` : ''}.`);}
else {return message.channel.send(`${user.id === message.author.id ? "You have" : "That person has"} watched **${ani.name}**.`);}
}
};

@ -25,7 +25,7 @@ module.exports = async (message, client, search, threshold=-10000, type='full')
.addField('Airing', `**Began:** ${an.airStartDate}\n**Ended:** ${an.isComplete ? an.airEndDate : 'This anime is still airing!'}`)
.addField("Cast", `**${an.characters.length} Characters**\n${(an.characters.length > 50 ? an.characters.slice(0, 49) : an.characters).map(char => client.misc.cache.charsID.get(char)).join(', ')}${an.characters.length > 50 ? `\n**+${an.characters.length - 50} Others**` : ''}`)
.addField('Other', `**Genre(s):** ${an.genres.join(", ")}\n**Tags:** ${an.tags.join(", ")}\n**Stream this at:** ${an.streamAt.join(", ")}${an.altNames && an.altNames.length ? `\n\n**Other names:** ${an.altNames.map(n => `\`${n}\``).join(', ')}` : ''}`)
.addField('Love', `**Watchers**: **${an.watchers} Natsuki ${client.utils.as(an.watchers, 'user')}** have this anime on their list of finished anime!\n\`n?watched ${an.name}\``)
.addField('Love', `**Watchers**: **${an.watchers} Natsuki ${client.utils.as(an.watchers, 'user')}** ${an.watchers === 1 ? 'has' : "have"} this anime on their list of finished anime!\n\`n?watched ${an.name}\``)
}
da.push(an.id);
return {embed: rte, id: an.id};

Loading…
Cancel
Save