Skip to content

Commit

Permalink
Fix ctcp request message (#4603)
Browse files Browse the repository at this point in the history
The message was ordered the wrong way in the TS rewrite.

Old:
    +bookworm sent a CTCP request: "chadler" to version
New:
    +bookworm sent a CTCP request: "version" to chadler
  • Loading branch information
brunnre8 committed Jul 7, 2022
1 parent d72d869 commit c8cd405
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions server/plugins/inputs/ctcp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,17 @@ const input: PluginInputHandler = function ({irc}, chan, cmd, args) {
}

const target = args.shift()!;
const type = args.shift()!;

chan.pushMessage(
this,
new Msg({
type: MessageType.CTCP_REQUEST,
ctcpMessage: `"${target}" to ${args[0]}`,
ctcpMessage: `"${type}" to ${target}`,
from: chan.getUser(irc.user.nick),
})
);

const type = args.shift()!;

irc.ctcpRequest(target, type, ...args);
};

Expand Down

0 comments on commit c8cd405

Please sign in to comment.