mirror of
https://gitlab.com/bignutty/labscore.git
synced 2025-06-07 13:43:06 -04:00
fix contextual query on wa when content is present (prefer userquery)
This commit is contained in:
parent
ecaaba9d3c
commit
e2c8a368c6
1 changed files with 1 additions and 2 deletions
|
@ -61,7 +61,7 @@ module.exports = {
|
|||
run: async (context, args) => {
|
||||
await acknowledge(context);
|
||||
|
||||
if(context.message.messageReference) {
|
||||
if(context.message.messageReference && !args.query.length) {
|
||||
let msg = await context.message.channel.fetchMessage(context.message.messageReference.messageId);
|
||||
if(msg.content && msg.content.length) args.query = msg.content
|
||||
if(msg.embeds?.length) for(const e of msg.embeds) if(e[1].description?.length) { args.query += '\n' + e[1].description; break; }
|
||||
|
@ -79,7 +79,6 @@ module.exports = {
|
|||
pages.push(createWolframPage(context, res, args.query, search.body.sources))
|
||||
}
|
||||
|
||||
|
||||
return await createDynamicCardStack(context, {
|
||||
cards: pages,
|
||||
interactive: {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue