mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-03-09 15:40:18 +00:00
SMBios improvements
This commit is contained in:
parent
82d6294ae2
commit
fa53e19f86
4 changed files with 25 additions and 78 deletions
|
@ -1357,7 +1357,7 @@ module.exports.CreateWebServer = function (parent, db, args, certificates) {
|
|||
// Indicates that any request to "/" should render "default" or "login" depending on login state
|
||||
function handleRootRequest(req, res, direct) {
|
||||
const domain = checkUserIpAddress(req, res);
|
||||
if (domain == null) { parent.debug('web', 'handleRootRequest: invalid domain.'); res.sendStatus(404); return; }
|
||||
if (domain == null) { parent.debug('web', 'handleRootRequest: invalid domain.'); try { res.sendStatus(404); } catch (ex) { } return; }
|
||||
if ((domain.loginkey != null) && (domain.loginkey.indexOf(req.query.key) == -1)) { res.sendStatus(404); return; } // Check 3FA URL key
|
||||
if (!obj.args) { parent.debug('web', 'handleRootRequest: no obj.args.'); res.sendStatus(500); return; }
|
||||
|
||||
|
@ -2910,7 +2910,7 @@ module.exports.CreateWebServer = function (parent, db, args, certificates) {
|
|||
// Require modules
|
||||
const archive = require('archiver')('zip', { level: 9 }); // Sets the compression method to maximum.
|
||||
|
||||
// Good practice to catch this error explicitly
|
||||
// Good practice to catch this error explicitly
|
||||
archive.on('error', function (err) { throw err; });
|
||||
|
||||
// Set the archive name
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue