mirror of
https://github.com/legop3/MultiRoombaRover.git
synced 2026-09-16 01:21:20 -04:00
no asterisks allowed in nicknames
This commit is contained in:
@@ -9,7 +9,8 @@ function sanitizeNickname(raw) {
|
||||
if (typeof raw !== 'string') return '';
|
||||
const trimmed = raw.trim();
|
||||
if (!trimmed) return '';
|
||||
return trimmed.slice(0, 32);
|
||||
const sanitized = trimmed.replace(/\*/g, 'nope');
|
||||
return sanitized.slice(0, 32);
|
||||
}
|
||||
|
||||
function getNickname(socket) {
|
||||
|
||||
Reference in New Issue
Block a user