mirror of
https://gitlab.com/bignutty/labscore.git
synced 2025-06-09 14:43:05 -04:00
fix no paginator entity being returned for only one page
This commit is contained in:
parent
c18265aee2
commit
ccc8fb0a9f
1 changed files with 1 additions and 6 deletions
|
@ -161,12 +161,7 @@ module.exports = class Paginator {
|
|||
|
||||
// No need for a paginator if we only have one page.
|
||||
if(data.pages.length == 1){
|
||||
let msg = data.pages[0];
|
||||
|
||||
if(!msg.message_reference) msg.reference = true
|
||||
if(!msg.allowedMentions) msg.allowedMentions = {parse: [], repliedUser: false}
|
||||
|
||||
return await data.context.editOrReply(msg);
|
||||
data.buttons = data.buttons.filter((i)=>!["next","previous"].includes(i))
|
||||
}
|
||||
|
||||
const instance = new InteractionPaginator(this, data);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue