mirror of https://github.com/calzoneman/sync.git
Expand chat message length option to be consistent with other options
This commit is contained in:
parent
986207b46b
commit
87198bd4e7
|
@ -129,7 +129,7 @@ max-accounts-per-ip: 5
|
|||
# Minimum number of seconds between guest logins from the same IP
|
||||
guest-login-delay: 60
|
||||
# Maximum character length of a chat message
|
||||
max-chat-msg-length: 320
|
||||
max-chat-message-length: 320
|
||||
|
||||
# Allows you to customize the path divider. The /r/ in http://localhost/r/yourchannel
|
||||
# Acceptable characters are a-z A-Z 0-9 _ and -
|
||||
|
|
|
@ -162,7 +162,7 @@ ChatModule.prototype.handleChatMsg = function (user, data) {
|
|||
return;
|
||||
}
|
||||
|
||||
data.msg = data.msg.substring(0, Config.get("max-chat-msg-length"));
|
||||
data.msg = data.msg.substring(0, Config.get("max-chat-message-length"));
|
||||
|
||||
// Restrict new accounts/IPs from chatting and posting links
|
||||
if (this.restrictNewAccount(user, data)) {
|
||||
|
@ -248,7 +248,7 @@ ChatModule.prototype.handlePm = function (user, data) {
|
|||
}
|
||||
|
||||
|
||||
data.msg = data.msg.substring(0, Config.get("max-chat-msg-length"));
|
||||
data.msg = data.msg.substring(0, Config.get("max-chat-message-length"));
|
||||
var to = null;
|
||||
for (var i = 0; i < this.channel.users.length; i++) {
|
||||
if (this.channel.users[i].getLowerName() === data.to) {
|
||||
|
|
|
@ -29,7 +29,7 @@ export default function initialize(app, ioConfig, chanPath, getBannedChannel) {
|
|||
sendPug(res, 'channel', {
|
||||
channelName: req.params.channel,
|
||||
sioSource: `${socketBaseURL}/socket.io/socket.io.js`,
|
||||
maxMsgLen: Config.get("max-chat-msg-length")
|
||||
maxMsgLen: Config.get("max-chat-message-length")
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue