1
0
Fork 0
mirror of https://github.com/Ylianst/MeshCentral.git synced 2025-03-09 15:40:18 +00:00

Added --removesubdomain command, #3440

This commit is contained in:
Ylian Saint-Hilaire 2022-01-11 17:30:50 -08:00
parent 7691265e32
commit 01dbc70098
5 changed files with 51 additions and 7 deletions

View file

@ -3516,6 +3516,7 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain, use
if (common.validateString(command.state, 1, 30000) == false) break; // Check state size, no more than 30k
command.state = parent.filterUserWebState(command.state); // Filter the state to remove anything bad
if ((command.state == null) || (typeof command.state !== 'string')) break; // If state did not validate correctly, quit here.
command.domain = domain.id;
db.Set({ _id: 'ws' + user._id, state: command.state });
parent.parent.DispatchEvent([user._id], obj, { action: 'userWebState', nolog: 1, domain: domain.id, state: command.state });
break;