3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-15 06:05:03 +00:00

Added Discord attachment link reaction, fixed emoji configuration and moved util functions

This commit is contained in:
Lily Bergonzat 2024-02-16 11:51:58 +01:00
parent a4c4b17a14
commit 592d037148
173 changed files with 1540 additions and 1170 deletions

View file

@ -1,7 +1,7 @@
import { commandTypeHelpers as ct } from "../../../commandTypes";
import { clearUpcomingReminder } from "../../../data/loops/upcomingRemindersLoop";
import { sendErrorMessage, sendSuccessMessage } from "../../../pluginUtils";
import { sorter } from "../../../utils";
import { CommonPlugin } from "../../Common/CommonPlugin";
import { remindersCmd } from "../types";
export const RemindersDeleteCmd = remindersCmd({
@ -17,7 +17,7 @@ export const RemindersDeleteCmd = remindersCmd({
reminders.sort(sorter("remind_at"));
if (args.num > reminders.length || args.num <= 0) {
sendErrorMessage(pluginData, msg.channel, "Unknown reminder");
pluginData.getPlugin(CommonPlugin).sendErrorMessage(msg, "Unknown reminder");
return;
}
@ -25,6 +25,6 @@ export const RemindersDeleteCmd = remindersCmd({
clearUpcomingReminder(toDelete);
await pluginData.state.reminders.delete(toDelete.id);
sendSuccessMessage(pluginData, msg.channel, "Reminder deleted");
pluginData.getPlugin(CommonPlugin).sendSuccessMessage(msg, "Reminder deleted");
},
});