mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-05 13:53:12 +02:00
Fix Gelbooru
This commit is contained in:
@@ -37,8 +37,8 @@ module.exports = class GelbooruCommand extends Command {
|
||||
const { posts } = await xml.parseStringAsync(text);
|
||||
if (posts.$.count === '0') return msg.say('No Results.');
|
||||
return msg.say(stripIndents`
|
||||
Result for ${query}:
|
||||
https:${posts.post[Math.floor(Math.random * posts.post.length)].$.file_url}
|
||||
${query ? `Result for ${query}:` : 'Random Image:'}
|
||||
https:${posts.post[Math.floor(Math.random() * posts.post.length)].$.file_url}
|
||||
`);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -37,7 +37,7 @@ module.exports = class Rule34Command extends Command {
|
||||
const { posts } = await xml.parseStringAsync(text);
|
||||
if (posts.$.count === '0') return msg.say('No Results.');
|
||||
return msg.say(stripIndents`
|
||||
Result for ${query}:
|
||||
${query ? `Result for ${query}:` : 'Random Image:'}
|
||||
https:${posts.post[Math.floor(Math.random() * posts.post.length)].$.file_url}
|
||||
`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user