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

Small server fixes.

This commit is contained in:
Ylian Saint-Hilaire 2019-03-17 19:34:52 -07:00
parent 0d8be5b6b3
commit ca43729470
16 changed files with 33 additions and 22 deletions

View file

@ -469,7 +469,7 @@ module.exports.CreateMeshAgent = function (parent, db, ws, req, args, domain) {
// Return the mesh for this device, in some cases, we may auto-create the mesh.
function getMeshAutoCreate() {
const mesh = parent.meshes[obj.dbMeshKey];
var mesh = parent.meshes[obj.dbMeshKey];
if ((mesh == null) && (typeof domain.orphanagentuser == 'string')) {
const adminUser = parent.users['user/' + domain.id + '/' + domain.orphanagentuser.toLowerCase()];
if ((adminUser != null) && (adminUser.siteadmin == 0xFFFFFFFF)) {