Merge branch 'develop' into feature/automated-weather-tests

# Conflicts:
#	modules/default/weather/weather.js
#	package-lock.json
#	package.json
This commit is contained in:
fewieden
2019-09-11 13:07:31 +02:00
121 changed files with 6959 additions and 4195 deletions

View File

@@ -16,7 +16,7 @@ var Utils = require(__dirname + "/../../js/utils.js");
/* getConfigFile()
* Return string with path of configuration file
* Check if set by enviroment variable MM_CONFIG_FILE
* Check if set by environment variable MM_CONFIG_FILE
*/
function getConfigFile() {
// FIXME: This function should be in core. Do you want refactor me ;) ?, be good!
@@ -35,7 +35,7 @@ function checkConfigFile() {
console.error(Utils.colors.error("File not found: "), configFileName);
return;
}
// check permision
// check permission
try {
fs.accessSync(configFileName, fs.F_OK);
} catch (e) {
@@ -52,12 +52,12 @@ function checkConfigFile() {
if (err) { throw err; }
v.JSHINT(data); // Parser by jshint
if (v.JSHINT.errors.length == 0) {
if (v.JSHINT.errors.length === 0) {
console.log("Your configuration file doesn't contain syntax errors :)");
return true;
} else {
errors = v.JSHINT.data().errors;
for (idx in errors) {
for (var idx in errors) {
error = errors[idx];
console.log("Line", error.line, "col", error.character, error.reason);
}
@@ -67,4 +67,4 @@ function checkConfigFile() {
if (process.env.NODE_ENV !== "test") {
checkConfigFile();
};
}

View File

@@ -1,4 +1,4 @@
/* Magic Mirror Test config sample enviroment
/* Magic Mirror Test config sample environment
*
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.

View File

@@ -6,7 +6,6 @@
* MIT Licensed.
*/
var config = {
port: 8080,
ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"],

View File

@@ -1,4 +1,4 @@
/* Magic Mirror Test config sample enviroment set por 8090
/* Magic Mirror Test config sample environment set port 8090
*
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.