From b397353dc6c5f13a48b5612c3ee0f8bbd1ed4a97 Mon Sep 17 00:00:00 2001 From: Ylian Saint-Hilaire Date: Fri, 26 Mar 2021 23:11:18 -0700 Subject: [PATCH] Added support for old web pages in createmesh command. --- meshuser.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/meshuser.js b/meshuser.js index 90a8b3eb..ece4bd3a 100644 --- a/meshuser.js +++ b/meshuser.js @@ -2905,6 +2905,9 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain, use { var err = null; try { + // Support for old web pages that sent the meshtype as a string. + if (typeof command.meshtype == 'string') { command.meshtype = parseInt(command.meshtype); } + // Check if we have new group restriction if ((user.siteadmin != SITERIGHT_ADMIN) && ((user.siteadmin & 64) != 0)) { err = 'Permission denied'; }