Skip to content

Commit

Permalink
Fix HoldGIFSend
Browse files Browse the repository at this point in the history
  • Loading branch information
pylixonly committed Aug 27, 2023
1 parent b36ff42 commit f1c5709
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
9 changes: 8 additions & 1 deletion plugins/HoldGIFSend/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,11 @@ import { instead } from "@vendetta/patcher";

const messageInputUtil = findByProps("selectGIF");

export const onUnload = instead("selectGIF", messageInputUtil, ([{ url }]) => messageInputUtil.insertText(url));
export const onUnload = instead("selectGIF", messageInputUtil, (args) => {
// args[1] never exists on older version, so we use it as an indicator
// prev: selectGIF([GIF]) now: selectGIF(currentChannelId, [GIF]);
if (args[1]) args[1] = args[1].url;
else args[0] = args[0].url;

messageInputUtil.insertText(...args);
});
2 changes: 2 additions & 0 deletions plugins/NoAutoReplyMention/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ export interface SettingsSchema {
storage.isBlacklistMode ??= false;
storage.exempted ??= [];

export const settings = storage as SettingsSchema;

const ReplyManager = findByProps("createPendingReply");

export default {
Expand Down

0 comments on commit f1c5709

Please sign in to comment.