mirror of
https://github.com/thelounge/thelounge.git
synced 2024-05-09 17:56:45 +02:00
24 lines
499 B
JavaScript
24 lines
499 B
JavaScript
"use strict";
|
|
|
|
exports.commands = ["quit"];
|
|
exports.allowDisconnected = true;
|
|
|
|
exports.input = function (network, chan, cmd, args) {
|
|
const client = this;
|
|
|
|
client.emit("confirm-dialog", {
|
|
title: "Remove network",
|
|
text: `Are you sure you want to quit and remove <b>${network.name}</b>? This cannot be undone.`,
|
|
button: "Remove network",
|
|
emit: {
|
|
target: "network:quit",
|
|
data: {
|
|
uuid: network.uuid,
|
|
quitMessage: args[0] ? args.join(" ") : null,
|
|
},
|
|
},
|
|
});
|
|
|
|
return true;
|
|
};
|