added mp4 support
This commit is contained in:
parent
9e960c9288
commit
963136bf74
6 changed files with 323 additions and 3 deletions
|
@ -29,7 +29,8 @@ export default {
|
|||
filename.endsWith(".wav") ||
|
||||
filename.endsWith(".ogg") ||
|
||||
filename.endsWith(".webm") ||
|
||||
filename.endsWith(".m4a")
|
||||
filename.endsWith(".m4a") ||
|
||||
filename.endsWith(".mp4")
|
||||
) {
|
||||
const filenameNoExtension = filename.split(".")[0];
|
||||
const files = fs.readdirSync("resources/soundboard");
|
||||
|
|
|
@ -8,7 +8,7 @@ export default {
|
|||
description: "forces bot to dm a user something (this will ghost ping them)",
|
||||
arguments: "user, message",
|
||||
execute(message, args) {
|
||||
const user = message.mentions.users.first();
|
||||
let user = message.mentions.users.first();
|
||||
const guild = message.guild;
|
||||
|
||||
if (!user) {
|
||||
|
|
|
@ -39,7 +39,6 @@ export default {
|
|||
});
|
||||
} else {
|
||||
const filestring = fs.readFileSync(path, "utf8");
|
||||
console.log(typeof filestring);
|
||||
action.sendMessage(
|
||||
message.channelId,
|
||||
filestring.slice(filestring.length - 500, filestring.length)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue