Compare commits

..

No commits in common. "61af290780071085dd3ca1211a5076409d5c5270" and "69afb24f63eb7f27f31a8502522eef2c5c2ee11d" have entirely different histories.

3 changed files with 9 additions and 15 deletions

4
package-lock.json generated
View File

@ -1,12 +1,12 @@
{ {
"name": "schat2-clive", "name": "schat2-clive",
"version": "1.9.2", "version": "1.9.1",
"lockfileVersion": 2, "lockfileVersion": 2,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "schat2-clive", "name": "schat2-clive",
"version": "1.9.2", "version": "1.9.1",
"license": "ISC", "license": "ISC",
"dependencies": { "dependencies": {
"bhttp": "^1.2.8", "bhttp": "^1.2.8",

View File

@ -1,6 +1,6 @@
{ {
"name": "schat2-clive", "name": "schat2-clive",
"version": "1.9.2", "version": "1.9.1",
"description": "Game host for SChat 2-powered chat sites", "description": "Game host for SChat 2-powered chat sites",
"main": "src/app.js", "main": "src/app.js",
"scripts": { "scripts": {

View File

@ -1,18 +1,12 @@
'use strict';
const config = require('config'); const config = require('config');
function onCommand(args, context) { function onCommand(args, context) {
if (config.platform === 'schat') { context.bot.socket.transmit('message', {
context.sendMessage('Shutting down... :sleeping:', context.room?.id, { type: 'message', label: false }, context.message.user?.username); roomId: context.room?.id,
} recipient: context.message.user?.username,
body: 'Shutting down... :sleeping:',
if (config.platform === 'irc' && context.room.id === config.user.nick) { style: config.style,
// if the room ID is the bot's own nickname, it's a PM and we should reply to the sender });
context.sendMessage('Shutting down... 😴', context.user.id, { label: false });
} else if (config.platform === 'irc') {
context.sendMessage('Shutting down... 😴', context.room?.id, { type: 'message', label: false });
}
context.logger.info(`Kill command used by ${context.user.username}`); context.logger.info(`Kill command used by ${context.user.username}`);