mirror of
https://github.com/hack-chat/main.git
synced 2024-03-22 13:20:33 +08:00
Gave emote its own event
This commit is contained in:
parent
96eacd92b1
commit
6a1a9df096
@ -42,13 +42,13 @@ export async function run({ server, socket, payload }) {
|
|||||||
text = ` ${text}`;
|
text = ` ${text}`;
|
||||||
}
|
}
|
||||||
|
|
||||||
// @todo Change `cmd` from `info` to it's own `emote` event
|
|
||||||
const newPayload = {
|
const newPayload = {
|
||||||
cmd: 'info',
|
cmd: 'emote',
|
||||||
type: 'emote',
|
|
||||||
nick: socket.nick,
|
nick: socket.nick,
|
||||||
|
userid: socket.userid,
|
||||||
text: `@${socket.nick}${text}`,
|
text: `@${socket.nick}${text}`,
|
||||||
};
|
};
|
||||||
|
|
||||||
if (socket.trip) {
|
if (socket.trip) {
|
||||||
newPayload.trip = socket.trip;
|
newPayload.trip = socket.trip;
|
||||||
}
|
}
|
||||||
|
@ -29,6 +29,5 @@ exports.Errors = {
|
|||||||
|
|
||||||
Invite: {
|
Invite: {
|
||||||
RATELIMIT: InviteErrors + 1,
|
RATELIMIT: InviteErrors + 1,
|
||||||
INVALID_LENGTH: InviteErrors + 2,
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user