mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-25 06:42:51 +02:00
Beep
This commit is contained in:
@@ -28,7 +28,7 @@ module.exports = class ThesaurusCommand extends Command {
|
|||||||
const { body } = await snekfetch
|
const { body } = await snekfetch
|
||||||
.get(`http://api.wordnik.com/v4/word.json/${query}/relatedWords`)
|
.get(`http://api.wordnik.com/v4/word.json/${query}/relatedWords`)
|
||||||
.query({
|
.query({
|
||||||
relationshipTypes: ['synonym', 'antonym'],
|
relationshipTypes: 'synonym,antonym',
|
||||||
limitPerRelationshipType: 5,
|
limitPerRelationshipType: 5,
|
||||||
api_key: WORDNIK_KEY
|
api_key: WORDNIK_KEY
|
||||||
});
|
});
|
||||||
@@ -38,9 +38,9 @@ module.exports = class ThesaurusCommand extends Command {
|
|||||||
const embed = new MessageEmbed()
|
const embed = new MessageEmbed()
|
||||||
.setColor(0x9797FF)
|
.setColor(0x9797FF)
|
||||||
.setTitle(query)
|
.setTitle(query)
|
||||||
.addField('> Synonyms',
|
.addField('❯ Synonyms',
|
||||||
synonyms ? synonyms.words.join(', ') : 'N/A')
|
synonyms ? synonyms.words.join(', ') : 'N/A')
|
||||||
.addField('> Antonyms',
|
.addField('❯ Antonyms',
|
||||||
antonyms ? antonyms.words.join(', ') : 'N/A');
|
antonyms ? antonyms.words.join(', ') : 'N/A');
|
||||||
return msg.embed(embed);
|
return msg.embed(embed);
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
|
|||||||
Reference in New Issue
Block a user