mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-23 18:05:01 +02:00
Fix
This commit is contained in:
@@ -20,7 +20,8 @@ module.exports = class DatingCommand extends ImgurAlbumCommand {
|
|||||||
memberName: 'dating',
|
memberName: 'dating',
|
||||||
description: 'Find the person of your dreams with this dating system!',
|
description: 'Find the person of your dreams with this dating system!',
|
||||||
clientPermissions: ['ATTACH_FILES'],
|
clientPermissions: ['ATTACH_FILES'],
|
||||||
albumID: DATING_ALBUM_ID
|
albumID: DATING_ALBUM_ID,
|
||||||
|
noImage: Boolean(DATING_OFF)
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -14,9 +14,11 @@ module.exports = class ImgurAlbumCommand extends Command {
|
|||||||
reason: 'API',
|
reason: 'API',
|
||||||
reasonURL: 'https://apidocs.imgur.com/'
|
reasonURL: 'https://apidocs.imgur.com/'
|
||||||
});
|
});
|
||||||
|
this.noImage = info.noImage;
|
||||||
}
|
}
|
||||||
|
|
||||||
async run(msg, { user }) {
|
async run(msg, { user }) {
|
||||||
|
if (this.noImage) return msg.say(this.generateText(msg, user));
|
||||||
try {
|
try {
|
||||||
const image = await this.random();
|
const image = await this.random();
|
||||||
if (!image) return msg.reply('This album has no images...');
|
if (!image) return msg.reply('This album has no images...');
|
||||||
|
|||||||
Reference in New Issue
Block a user