fix random & search
This commit is contained in:
@ -25,7 +25,7 @@ export default async bot => {
|
||||
return e.reply("no f0cks given! lol D:");
|
||||
|
||||
e.reply([
|
||||
`${cfg.main.url}/${rows[0].id}`,
|
||||
`${cfg.main.url.full}/${rows[0].id}`,
|
||||
`user: ${rows[0].username} @ ${rows[0].usernetwork} ${rows[0].userchannel}`,
|
||||
`~${lib.formatSize(rows[0].size)}`,
|
||||
rows[0].mime,
|
||||
|
@ -24,7 +24,7 @@ export default async bot => {
|
||||
if(rows.length === 0)
|
||||
return e.reply("nothing found, f0cker");
|
||||
|
||||
return e.reply(`f0ckrnd: ${cfg.main.url}/${rows[0].id} by: ${rows[0].username} (${rows[0].mime}, ~${lib.formatSize(rows[0].size)})`);
|
||||
return e.reply(`f0ckrnd: ${cfg.main.url.full}/${rows[0].id} by: ${rows[0].username} (${rows[0].mime}, ~${lib.formatSize(rows[0].size)})`);
|
||||
}
|
||||
}];
|
||||
};
|
||||
|
@ -51,7 +51,7 @@ export default async bot => {
|
||||
where src = ${link}
|
||||
`;
|
||||
if(q_repost.length > 0)
|
||||
return e.reply(`repost motherf0cker (link): ${cfg.main.url}/${q_repost[0].id}`);
|
||||
return e.reply(`repost motherf0cker (link): ${cfg.main.url.full}/${q_repost[0].id}`);
|
||||
|
||||
// generate uuid
|
||||
const uuid = (await db`
|
||||
@ -120,7 +120,7 @@ export default async bot => {
|
||||
where checksum = ${checksum}
|
||||
`;
|
||||
if(q_repostc.length > 0)
|
||||
return e.reply(`repost motherf0cker (checksum): ${cfg.main.url}/${q_repostc[0].id}`);
|
||||
return e.reply(`repost motherf0cker (checksum): ${cfg.main.url.full}/${q_repostc[0].id}`);
|
||||
|
||||
await fs.promises.copyFile(`./tmp/${filename}`, `./public/b/${filename}`);
|
||||
await fs.promises.unlink(`./tmp/${filename}`).catch(_=>{});
|
||||
@ -241,7 +241,7 @@ export default async bot => {
|
||||
}
|
||||
|
||||
e.reply([
|
||||
`[f0cked] link: ${cfg.main.url}/${itemid} | size: ${lib.formatSize(size)} | speed: ${speed}` + (tags.length > 0 ? ` | tags: ${tags.join(', ')}` : '')
|
||||
`[f0cked] link: ${cfg.main.url.full}/${itemid} | size: ${lib.formatSize(size)} | speed: ${speed}` + (tags.length > 0 ? ` | tags: ${tags.join(', ')}` : '')
|
||||
]);
|
||||
|
||||
});
|
||||
|
@ -15,8 +15,8 @@ export default async bot => {
|
||||
return e.reply("lol no");
|
||||
const tags = (await lib.getTags(id)).map(t => t.tag);
|
||||
if(tags.length === 0)
|
||||
return e.reply(`item ${cfg.main.url}/${id} has no tags!`);
|
||||
return e.reply(`item ${cfg.main.url}/${id} is tagged as: ${tags.join(', ')}`);
|
||||
return e.reply(`item ${cfg.main.url.full}/${id} has no tags!`);
|
||||
return e.reply(`item ${cfg.main.url.full}/${id} is tagged as: ${tags.join(', ')}`);
|
||||
}
|
||||
}, {
|
||||
name: "tags add",
|
||||
@ -73,8 +73,8 @@ export default async bot => {
|
||||
|
||||
const ntags = (await lib.getTags(id)).map(t => t.tag);
|
||||
if(ntags.length === 0)
|
||||
return e.reply(`item ${cfg.main.url}/${id} has no tags!`);
|
||||
return e.reply(`item ${cfg.main.url}/${id} is now tagged as: ${ntags.join(', ')}`);
|
||||
return e.reply(`item ${cfg.main.url.full}/${id} has no tags!`);
|
||||
return e.reply(`item ${cfg.main.url.full}/${id} is now tagged as: ${ntags.join(', ')}`);
|
||||
}
|
||||
}, {
|
||||
name: "tags remove",
|
||||
@ -126,8 +126,8 @@ export default async bot => {
|
||||
|
||||
const ntags = (await lib.getTags(id)).map(t => t.tag);
|
||||
if(ntags.length === 0)
|
||||
return e.reply(`item ${cfg.main.url}/${id} has no tags!`);
|
||||
return e.reply(`item ${cfg.main.url}/${id} is now tagged as: ${ntags.join(', ')}`);
|
||||
return e.reply(`item ${cfg.main.url.full}/${id} has no tags!`);
|
||||
return e.reply(`item ${cfg.main.url.full}/${id} is now tagged as: ${ntags.join(', ')}`);
|
||||
}
|
||||
}]
|
||||
};
|
||||
|
Reference in New Issue
Block a user