mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-11-10 22:10:09 -05:00
Fix for Node 11.10 deprecation of require('constants').
This commit is contained in:
@@ -59,7 +59,7 @@ module.exports.CreateWebServer = function (parent, db, args, certificates) {
|
||||
obj.meshRelayHandler = require('./meshrelay.js');
|
||||
obj.meshUserHandler = require('./meshuser.js');
|
||||
obj.interceptor = require('./interceptor');
|
||||
const constants = require('constants');
|
||||
const constants = (obj.crypto.constants ? obj.crypto.constants : require('constants')); // require('constants') is deprecated in Node 11.10, use require('crypto').constants instead.
|
||||
|
||||
// Variables
|
||||
obj.parent = parent;
|
||||
|
||||
Reference in New Issue
Block a user