mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2024-09-11 08:55:32 +03:00
Fixed server crash when meshcentral-web has no translations.
This commit is contained in:
parent
790d5be6e9
commit
6ff9037f8e
@ -4398,9 +4398,8 @@ module.exports.CreateWebServer = function (parent, db, args, certificates) {
|
||||
}
|
||||
|
||||
// See if there are any custom rending pages that will override the default ones
|
||||
if (obj.parent.webViewsOverridePath != null) {
|
||||
translateFolder = null;
|
||||
if (obj.fs.existsSync(obj.path.join(obj.parent.webViewsOverridePath, 'translations'))) { translateFolder = obj.path.join(obj.parent.webViewsOverridePath, 'translations'); }
|
||||
if ((obj.parent.webViewsOverridePath != null) && (obj.fs.existsSync(obj.path.join(obj.parent.webViewsOverridePath, 'translations')))) {
|
||||
translateFolder = obj.path.join(obj.parent.webViewsOverridePath, 'translations');
|
||||
var files = obj.fs.readdirSync(translateFolder);
|
||||
for (var i in files) {
|
||||
var name = files[i];
|
||||
|
Loading…
Reference in New Issue
Block a user