Fixed Linux interactive installer.

Ylian Saint-Hilaire committed Sep 14, 2020 at 13:32 UTC 7c65186892ea615384ea36e9de9598539fb840bc
2 files changed +4 -4
agents/meshinstall-linux.js
+3 -1
@@ -14,7 +14,9 @@ See the License for the specific language governing permissions and
14 limitations under the License.
15 */
16
17 -var s = null, msh = {}, buttons = ['Cancel'], skip = false;
17 +// The folloing line just below with 'msh=' needs to stay exactly like this since MeshCentral will replace it with the correct settings.
18 +var msh = {};
19 +var s = null, buttons = ['Cancel'], skip = false;
20 try { s = require('service-manager').manager.getService('meshagent'); } catch (e) { }
21
22 function _install(parms) {
meshuser.js
+1 -3
@@ -4468,9 +4468,7 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain, use
4468 break;
4469 }
4470 case 'createDeviceShareLink': {
4471 - var maxExpireMinutes = (typeof domain.maxguestsessionsharingtime == 'number') ? domain.maxguestsessionsharingtime : 60;
4472 - console.log(maxExpireMinutes);
4473 - var err = null;
4471 + var err = null, maxExpireMinutes = (typeof domain.maxguestsessionsharingtime == 'number') ? domain.maxguestsessionsharingtime : 60;
4472 if (common.validateString(command.nodeid, 8, 128) == false) { err = 'Invalid node id'; } // Check the meshid
4473 else if (common.validateString(command.guestname, 1, 128) == false) { err = 'Invalid guest name'; } // Check the guest name
4474 else if (common.validateInt(command.expire, 1, maxExpireMinutes) == false) { err = 'Invalid expire time'; } // Check the expire time in hours