mirror of
https://github.com/thelounge/thelounge
synced 2024-11-26 22:10:22 +00:00
dd05ee3a65
Co-authored-by: Eric Nemchik <eric@nemchik.com> Co-authored-by: Pavel Djundik <xPaw@users.noreply.github.com>
19 lines
436 B
TypeScript
19 lines
436 B
TypeScript
import Msg, {MessageType} from "../../models/msg";
|
|
import {IrcEventHandler} from "../../client";
|
|
|
|
export default <IrcEventHandler>function (irc, network) {
|
|
const client = this;
|
|
|
|
irc.on("info", function (data) {
|
|
const lobby = network.channels[0];
|
|
|
|
if (data.info) {
|
|
const msg = new Msg({
|
|
type: MessageType.MONOSPACE_BLOCK,
|
|
command: "info",
|
|
text: data.info,
|
|
});
|
|
lobby.pushMessage(client, msg, true);
|
|
}
|
|
});
|
|
};
|