Merge conflict.

This commit is contained in:
Michael Teeuw 2019-06-14 13:19:29 +02:00
commit 7a272ef0ab
70 changed files with 2261 additions and 2633 deletions

View File

@ -3,4 +3,3 @@ vendor/*
!/modules/default/** !/modules/default/**
!/modules/node_helper !/modules/node_helper
!/modules/node_helper/** !/modules/node_helper/**
!/modules/default/defaultmodules.js

View File

@ -2,9 +2,11 @@
"rules": { "rules": {
"indent": ["error", "tab"], "indent": ["error", "tab"],
"quotes": ["error", "double"], "quotes": ["error", "double"],
"semi": ["error"],
"max-len": ["error", 250], "max-len": ["error", 250],
"curly": "error", "curly": "error",
"camelcase": ["error", {"properties": "never"}], "camelcase": ["error", {"properties": "never"}],
"no-multiple-empty-lines": ["error", { "max": 1, "maxEOF": 1 }],
"no-trailing-spaces": ["error", {"ignoreComments": false }], "no-trailing-spaces": ["error", {"ignoreComments": false }],
"no-irregular-whitespace": ["error"] "no-irregular-whitespace": ["error"]
}, },

View File

@ -40,6 +40,7 @@ Added UK Met Office Datapoint feed as a provider in the default weather module.
- Handle SIGTERM messages - Handle SIGTERM messages
- Fixes sliceMultiDayEvents so it respects maximumNumberOfDays - Fixes sliceMultiDayEvents so it respects maximumNumberOfDays
- Minor types in default NewsFeed [README.md](https://github.com/MichMich/MagicMirror/blob/develop/modules/default/newsfeed/README.md) - Minor types in default NewsFeed [README.md](https://github.com/MichMich/MagicMirror/blob/develop/modules/default/newsfeed/README.md)
- Fix typos and small syntax errors, cleanup dependencies, remove multiple-empty-lines, add semi-rule
## [2.7.1] - 2019-04-02 ## [2.7.1] - 2019-04-02

View File

@ -26,7 +26,7 @@ module.exports = function(grunt) {
stylelint: { stylelint: {
simple: { simple: {
options: { options: {
configFile: ".stylelintrc" configFile: ".stylelintrc.json"
}, },
src: [ src: [
"css/main.css", "css/main.css",
@ -42,11 +42,11 @@ module.exports = function(grunt) {
src: [ src: [
"package.json", "package.json",
".eslintrc.json", ".eslintrc.json",
".stylelintrc", ".stylelintrc.json",
"installers/pm2_MagicMirror.json",
"translations/*.json", "translations/*.json",
"modules/default/*/translations/*.json", "modules/default/*/translations/*.json",
"installers/pm2_MagicMirror.json", "vendor/package.json"
"vendor/package.js"
], ],
options: { options: {
reporter: "jshint" reporter: "jshint"

View File

@ -5,7 +5,7 @@
<a href="https://david-dm.org/MichMich/MagicMirror#info=devDependencies"><img src="https://david-dm.org/MichMich/MagicMirror/dev-status.svg" alt="devDependency Status"></a> <a href="https://david-dm.org/MichMich/MagicMirror#info=devDependencies"><img src="https://david-dm.org/MichMich/MagicMirror/dev-status.svg" alt="devDependency Status"></a>
<a href="https://bestpractices.coreinfrastructure.org/projects/347"><img src="https://bestpractices.coreinfrastructure.org/projects/347/badge"></a> <a href="https://bestpractices.coreinfrastructure.org/projects/347"><img src="https://bestpractices.coreinfrastructure.org/projects/347/badge"></a>
<a href="http://choosealicense.com/licenses/mit"><img src="https://img.shields.io/badge/license-MIT-blue.svg" alt="License"></a> <a href="http://choosealicense.com/licenses/mit"><img src="https://img.shields.io/badge/license-MIT-blue.svg" alt="License"></a>
<a href="https://travis-ci.org/MichMich/MagicMirror"><img src="https://travis-ci.org/MichMich/MagicMirror.svg" alt="Travis"></a> <a href="https://travis-ci.com/MichMich/MagicMirror"><img src="https://travis-ci.com/MichMich/MagicMirror.svg" alt="Travis"></a>
<a href="https://snyk.io/test/github/MichMich/MagicMirror"><img src="https://snyk.io/test/github/MichMich/MagicMirror/badge.svg" alt="Known Vulnerabilities" data-canonical-src="https://snyk.io/test/github/MichMich/MagicMirror" style="max-width:100%;"></a> <a href="https://snyk.io/test/github/MichMich/MagicMirror"><img src="https://snyk.io/test/github/MichMich/MagicMirror/badge.svg" alt="Known Vulnerabilities" data-canonical-src="https://snyk.io/test/github/MichMich/MagicMirror" style="max-width:100%;"></a>
</p> </p>

View File

@ -2,7 +2,7 @@
"use strict"; "use strict";
// Use seperate scope to prevent global scope pollution // Use separate scope to prevent global scope pollution
(function () { (function () {
var config = {}; var config = {};
@ -19,7 +19,7 @@
// Prefer command line arguments over environment variables // Prefer command line arguments over environment variables
["address", "port"].forEach((key) => { ["address", "port"].forEach((key) => {
config[key] = getCommandLineParameter(key, process.env[key.toUpperCase()]); config[key] = getCommandLineParameter(key, process.env[key.toUpperCase()]);
}) });
} }
function getServerConfig(url) { function getServerConfig(url) {
@ -30,7 +30,7 @@
const request = lib.get(url, (response) => { const request = lib.get(url, (response) => {
var configData = ""; var configData = "";
// Gather incomming data // Gather incoming data
response.on("data", function(chunk) { response.on("data", function(chunk) {
configData += chunk; configData += chunk;
}); });
@ -43,8 +43,8 @@
request.on("error", function(error) { request.on("error", function(error) {
reject(new Error(`Unable to read config from server (${url} (${error.message}`)); reject(new Error(`Unable to read config from server (${url} (${error.message}`));
}); });
}) });
}; }
function fail(message, code = 1) { function fail(message, code = 1) {
if (message !== undefined && typeof message === "string") { if (message !== undefined && typeof message === "string") {
@ -89,7 +89,7 @@
}); });
child.on("close", (code) => { child.on("close", (code) => {
if (code != 0) { if (code !== 0) {
console.log(`There something wrong. The clientonly is not running code ${code}`); console.log(`There something wrong. The clientonly is not running code ${code}`);
} }
}); });

View File

@ -1,9 +1,9 @@
import { danger, fail, warn } from "danger" import { danger, fail, warn } from "danger";
// Check if the CHANGELOG.md file has been edited // Check if the CHANGELOG.md file has been edited
// Fail the build and post a comment reminding submitters to do so if it wasn't changed // Fail the build and post a comment reminding submitters to do so if it wasn't changed
if (!danger.git.modified_files.includes("CHANGELOG.md")) { if (!danger.git.modified_files.includes("CHANGELOG.md")) {
warn("Please include an updated `CHANGELOG.md` file.<br>This way we can keep track of all the contributions.") warn("Please include an updated `CHANGELOG.md` file.<br>This way we can keep track of all the contributions.");
} }
// Check if the PR request is send to the master branch. // Check if the PR request is send to the master branch.
@ -12,6 +12,6 @@ if (danger.github.pr.base.ref === "master" && danger.github.pr.user.login !== "M
// Check if the PR body or title includes the text: #accepted. // Check if the PR body or title includes the text: #accepted.
// If not, the PR will fail. // If not, the PR will fail.
if ((danger.github.pr.body + danger.github.pr.title).includes("#accepted")) { if ((danger.github.pr.body + danger.github.pr.title).includes("#accepted")) {
fail("Please send all your pull requests to the `develop` branch.<br>Pull requests on the `master` branch will not be accepted.") fail("Please send all your pull requests to the `develop` branch.<br>Pull requests on the `master` branch will not be accepted.");
} }
} }

View File

@ -48,7 +48,6 @@ var App = function() {
* *
* argument callback function - The callback function. * argument callback function - The callback function.
*/ */
var loadConfig = function(callback) { var loadConfig = function(callback) {
console.log("Loading config ..."); console.log("Loading config ...");
var defaults = require(__dirname + "/defaults.js"); var defaults = require(__dirname + "/defaults.js");
@ -67,7 +66,7 @@ var App = function() {
var config = Object.assign(defaults, c); var config = Object.assign(defaults, c);
callback(config); callback(config);
} catch (e) { } catch (e) {
if (e.code == "ENOENT") { if (e.code === "ENOENT") {
console.error(Utils.colors.error("WARNING! Could not find config file. Please create one. Starting with default configuration.")); console.error(Utils.colors.error("WARNING! Could not find config file. Please create one. Starting with default configuration."));
} else if (e instanceof ReferenceError || e instanceof SyntaxError) { } else if (e instanceof ReferenceError || e instanceof SyntaxError) {
console.error(Utils.colors.error("WARNING! Could not validate config file. Starting with default configuration. Please correct syntax errors at or above this line: " + e.stack)); console.error(Utils.colors.error("WARNING! Could not validate config file. Starting with default configuration. Please correct syntax errors at or above this line: " + e.stack));
@ -96,7 +95,7 @@ var App = function() {
". Check README and CHANGELOG for more up-to-date ways of getting the same functionality.") ". Check README and CHANGELOG for more up-to-date ways of getting the same functionality.")
); );
} }
} };
/* loadModule(module) /* loadModule(module)
* Loads a specific module. * Loads a specific module.
@ -173,7 +172,7 @@ var App = function() {
}; };
/* cmpVersions(a,b) /* cmpVersions(a,b)
* Compare two symantic version numbers and return the difference. * Compare two semantic version numbers and return the difference.
* *
* argument a string - Version number a. * argument a string - Version number a.
* argument a string - Version number b. * argument a string - Version number b.
@ -197,7 +196,7 @@ var App = function() {
/* start(callback) /* start(callback)
* This methods starts the core app. * This methods starts the core app.
* It loads the config, then it loads all modules. * It loads the config, then it loads all modules.
* When it"s done it executs the callback with the config as argument. * When it's done it executes the callback with the config as argument.
* *
* argument callback function - The callback function. * argument callback function - The callback function.
*/ */
@ -231,7 +230,6 @@ var App = function() {
if (typeof callback === "function") { if (typeof callback === "function") {
callback(config); callback(config);
} }
}); });
}); });
}); });

View File

@ -21,7 +21,7 @@
var prototype = new this(); var prototype = new this();
initializing = false; initializing = false;
// Make a copy of all prototype properies, to prevent reference issues. // Make a copy of all prototype properties, to prevent reference issues.
for (var name in prototype) { for (var name in prototype) {
prototype[name] = cloneObject(prototype[name]); prototype[name] = cloneObject(prototype[name]);
} }
@ -29,8 +29,8 @@
// Copy the properties over onto the new prototype // Copy the properties over onto the new prototype
for (var name in prop) { for (var name in prop) {
// Check if we're overwriting an existing function // Check if we're overwriting an existing function
prototype[name] = typeof prop[name] == "function" && prototype[name] = typeof prop[name] === "function" &&
typeof _super[name] == "function" && fnTest.test(prop[name]) ? (function (name, fn) { typeof _super[name] === "function" && fnTest.test(prop[name]) ? (function (name, fn) {
return function () { return function () {
var tmp = this._super; var tmp = this._super;
@ -43,7 +43,6 @@
var ret = fn.apply(this, arguments); var ret = fn.apply(this, arguments);
this._super = tmp; this._super = tmp;
return ret; return ret;
}; };
})(name, prop[name]) : prop[name]; })(name, prop[name]) : prop[name];

View File

@ -8,7 +8,7 @@
var Loader = (function() { var Loader = (function() {
/* Create helper valiables */ /* Create helper variables */
var loadedModuleFiles = []; var loadedModuleFiles = [];
var loadedFiles = []; var loadedFiles = [];
@ -55,7 +55,7 @@ var Loader = (function() {
module.start(); module.start();
} }
// Notifiy core of loded modules. // Notify core of loaded modules.
MM.modulesStarted(moduleObjects); MM.modulesStarted(moduleObjects);
}; };
@ -104,7 +104,6 @@ var Loader = (function() {
config: moduleData.config, config: moduleData.config,
classes: (typeof moduleData.classes !== "undefined") ? moduleData.classes + " " + module : module classes: (typeof moduleData.classes !== "undefined") ? moduleData.classes + " " + module : module
}); });
} }
return moduleFiles; return moduleFiles;
@ -138,7 +137,6 @@ var Loader = (function() {
afterLoad(); afterLoad();
}); });
} }
}; };
/* bootstrapModule(module, mObj) /* bootstrapModule(module, mObj)
@ -164,7 +162,6 @@ var Loader = (function() {
}); });
}); });
}); });
}; };
/* loadFile(fileName) /* loadFile(fileName)
@ -210,7 +207,6 @@ var Loader = (function() {
document.getElementsByTagName("head")[0].appendChild(stylesheet); document.getElementsByTagName("head")[0].appendChild(stylesheet);
break; break;
} }
}; };
/* Public Methods */ /* Public Methods */
@ -261,5 +257,4 @@ var Loader = (function() {
loadFile(module.file(fileName), callback); loadFile(module.file(fileName), callback);
} }
}; };
})(); })();

View File

@ -291,7 +291,7 @@ var MM = (function() {
var moduleWrapper = document.getElementById(module.identifier); var moduleWrapper = document.getElementById(module.identifier);
if (moduleWrapper !== null) { if (moduleWrapper !== null) {
moduleWrapper.style.transition = "opacity " + speed / 1000 + "s"; moduleWrapper.style.transition = "opacity " + speed / 1000 + "s";
// Restore the postition. See hideModule() for more info. // Restore the position. See hideModule() for more info.
moduleWrapper.style.position = "static"; moduleWrapper.style.position = "static";
updateWrapperStates(); updateWrapperStates();
@ -311,7 +311,7 @@ var MM = (function() {
/* updateWrapperStates() /* updateWrapperStates()
* Checks for all positions if it has visible content. * Checks for all positions if it has visible content.
* If not, if will hide the position to prevent unwanted margins. * If not, if will hide the position to prevent unwanted margins.
* This method schould be called by the show and hide methods. * This method should be called by the show and hide methods.
* *
* Example: * Example:
* If the top_bar only contains the update notification. And no update is available, * If the top_bar only contains the update notification. And no update is available,
@ -319,7 +319,6 @@ var MM = (function() {
* an ugly top margin. By using this function, the top bar will be hidden if the * an ugly top margin. By using this function, the top bar will be hidden if the
* update notification is not visible. * update notification is not visible.
*/ */
var updateWrapperStates = function() { var updateWrapperStates = function() {
var positions = ["top_bar", "top_left", "top_center", "top_right", "upper_third", "middle_center", "lower_third", "bottom_left", "bottom_center", "bottom_right", "bottom_bar", "fullscreen_above", "fullscreen_below"]; var positions = ["top_bar", "top_left", "top_center", "top_right", "upper_third", "middle_center", "lower_third", "bottom_left", "bottom_center", "bottom_right", "bottom_bar", "fullscreen_above", "fullscreen_below"];
@ -329,7 +328,7 @@ var MM = (function() {
var showWrapper = false; var showWrapper = false;
Array.prototype.forEach.call(moduleWrappers, function(moduleWrapper) { Array.prototype.forEach.call(moduleWrappers, function(moduleWrapper) {
if (moduleWrapper.style.position == "" || moduleWrapper.style.position == "static") { if (moduleWrapper.style.position === "" || moduleWrapper.style.position === "static") {
showWrapper = true; showWrapper = true;
} }
}); });
@ -478,7 +477,7 @@ var MM = (function() {
/* sendNotification(notification, payload, sender) /* sendNotification(notification, payload, sender)
* Send a notification to all modules. * Send a notification to all modules.
* *
* argument notification string - The identifier of the noitication. * argument notification string - The identifier of the notification.
* argument payload mixed - The payload of the notification. * argument payload mixed - The payload of the notification.
* argument sender Module - The module that sent the notification. * argument sender Module - The module that sent the notification.
*/ */
@ -558,7 +557,7 @@ var MM = (function() {
})(); })();
// Add polyfill for Object.assign. // Add polyfill for Object.assign.
if (typeof Object.assign != "function") { if (typeof Object.assign !== "function") {
(function() { (function() {
Object.assign = function(target) { Object.assign = function(target) {
"use strict"; "use strict";

View File

@ -76,7 +76,7 @@ var Module = Class.extend({
/* getDom() /* getDom()
* This method generates the dom which needs to be displayed. This method is called by the Magic Mirror core. * This method generates the dom which needs to be displayed. This method is called by the Magic Mirror core.
* This method can to be subclassed if the module wants to display info on the mirror. * This method can to be subclassed if the module wants to display info on the mirror.
* Alternatively, the getTemplete method could be subclassed. * Alternatively, the getTemplate method could be subclassed.
* *
* return DomObject | Promise - The dom or a promise with the dom to display. * return DomObject | Promise - The dom or a promise with the dom to display.
*/ */
@ -92,7 +92,7 @@ var Module = Class.extend({
// the template is a filename // the template is a filename
self.nunjucksEnvironment().render(template, templateData, function (err, res) { self.nunjucksEnvironment().render(template, templateData, function (err, res) {
if (err) { if (err) {
Log.error(err) Log.error(err);
} }
div.innerHTML = res; div.innerHTML = res;
@ -121,7 +121,7 @@ var Module = Class.extend({
/* getTemplate() /* getTemplate()
* This method returns the template for the module which is used by the default getDom implementation. * This method returns the template for the module which is used by the default getDom implementation.
* This method needs to be subclassed if the module wants to use a tempate. * This method needs to be subclassed if the module wants to use a template.
* It can either return a template sting, or a template filename. * It can either return a template sting, or a template filename.
* If the string ends with '.html' it's considered a file from within the module's folder. * If the string ends with '.html' it's considered a file from within the module's folder.
* *
@ -138,7 +138,7 @@ var Module = Class.extend({
* return Object * return Object
*/ */
getTemplateData: function () { getTemplateData: function () {
return {} return {};
}, },
/* notificationReceived(notification, payload, sender) /* notificationReceived(notification, payload, sender)
@ -164,7 +164,7 @@ var Module = Class.extend({
* @returns Nunjucks Environment * @returns Nunjucks Environment
*/ */
nunjucksEnvironment: function() { nunjucksEnvironment: function() {
if (this._nunjucksEnvironment != null) { if (this._nunjucksEnvironment !== null) {
return this._nunjucksEnvironment; return this._nunjucksEnvironment;
} }
@ -175,7 +175,7 @@ var Module = Class.extend({
lstripBlocks: true lstripBlocks: true
}); });
this._nunjucksEnvironment.addFilter("translate", function(str) { this._nunjucksEnvironment.addFilter("translate", function(str) {
return self.translate(str) return self.translate(str);
}); });
return this._nunjucksEnvironment; return this._nunjucksEnvironment;
@ -233,7 +233,7 @@ var Module = Class.extend({
}, },
/* socket() /* socket()
* Returns a socket object. If it doesn"t exist, it"s created. * Returns a socket object. If it doesn't exist, it"s created.
* It also registers the notification callback. * It also registers the notification callback.
*/ */
socket: function () { socket: function () {
@ -438,11 +438,10 @@ Module.create = function (name) {
var ModuleClass = Module.extend(clonedDefinition); var ModuleClass = Module.extend(clonedDefinition);
return new ModuleClass(); return new ModuleClass();
}; };
/* cmpVersions(a,b) /* cmpVersions(a,b)
* Compare two symantic version numbers and return the difference. * Compare two semantic version numbers and return the difference.
* *
* argument a string - Version number a. * argument a string - Version number a.
* argument a string - Version number b. * argument a string - Version number b.

View File

@ -26,8 +26,8 @@ var Server = function(config, callback) {
server.listen(port, config.address ? config.address : null); server.listen(port, config.address ? config.address : null);
if (config.ipWhitelist instanceof Array && config.ipWhitelist.length == 0) { if (config.ipWhitelist instanceof Array && config.ipWhitelist.length === 0) {
console.info(Utils.colors.warn("You're using a full whitelist configuration to allow for all IPs")) console.info(Utils.colors.warn("You're using a full whitelist configuration to allow for all IPs"));
} }
app.use(function(req, res, next) { app.use(function(req, res, next) {

View File

@ -18,7 +18,7 @@ var Translator = (function() {
xhr.overrideMimeType("application/json"); xhr.overrideMimeType("application/json");
xhr.open("GET", file, true); xhr.open("GET", file, true);
xhr.onreadystatechange = function () { xhr.onreadystatechange = function () {
if (xhr.readyState == 4 && xhr.status == "200") { if (xhr.readyState === 4 && xhr.status === 200) {
callback(JSON.parse(stripComments(xhr.responseText))); callback(JSON.parse(stripComments(xhr.responseText)));
} }
}; };
@ -159,6 +159,7 @@ var Translator = (function() {
return key; return key;
}, },
/* load(module, file, isFallback, callback) /* load(module, file, isFallback, callback)
* Load a translation file (json) and remember the data. * Load a translation file (json) and remember the data.
* *

View File

@ -35,13 +35,13 @@ Module.register("alert",{
}; };
}, },
show_notification: function(message) { show_notification: function(message) {
if (this.config.effect == "slide") {this.config.effect = this.config.effect + "-" + this.config.position;} if (this.config.effect === "slide") {this.config.effect = this.config.effect + "-" + this.config.position;}
msg = ""; msg = "";
if (message.title) { if (message.title) {
msg += "<span class='thin dimmed medium'>" + message.title + "</span>"; msg += "<span class='thin dimmed medium'>" + message.title + "</span>";
} }
if (message.message){ if (message.message){
if (msg != ""){ if (msg !== ""){
msg+= "<br />"; msg+= "<br />";
} }
msg += "<span class='light bright small'>" + message.message + "</span>"; msg += "<span class='light bright small'>" + message.message + "</span>";
@ -132,7 +132,7 @@ Module.register("alert",{
if (typeof payload.type === "undefined") { payload.type = "alert"; } if (typeof payload.type === "undefined") { payload.type = "alert"; }
if (payload.type === "alert") { if (payload.type === "alert") {
this.show_alert(payload, sender); this.show_alert(payload, sender);
} else if (payload.type = "notification") { } else if (payload.type === "notification") {
this.show_notification(payload); this.show_notification(payload);
} }
} else if (notification === "HIDE_ALERT") { } else if (notification === "HIDE_ALERT") {
@ -152,5 +152,4 @@ Module.register("alert",{
} }
Log.info("Starting module: " + this.name); Log.info("Starting module: " + this.name);
} }
}); });

View File

@ -105,7 +105,7 @@ Module.register("calendar", {
calendar.auth = { calendar.auth = {
user: calendar.user, user: calendar.user,
pass: calendar.pass pass: calendar.pass
} };
} }
this.addCalendar(calendar.url, calendar.auth, calendarConfig); this.addCalendar(calendar.url, calendar.auth, calendarConfig);
@ -191,7 +191,6 @@ Module.register("calendar", {
} }
} }
var eventWrapper = document.createElement("tr"); var eventWrapper = document.createElement("tr");
if (this.config.colored && !this.config.coloredSymbolOnly) { if (this.config.colored && !this.config.coloredSymbolOnly) {
@ -224,7 +223,7 @@ Module.register("calendar", {
symbolWrapper.appendChild(symbol); symbolWrapper.appendChild(symbol);
} }
eventWrapper.appendChild(symbolWrapper); eventWrapper.appendChild(symbolWrapper);
}else if(this.config.timeFormat === "dateheaders"){ } else if(this.config.timeFormat === "dateheaders"){
var blankCell = document.createElement("td"); var blankCell = document.createElement("td");
blankCell.innerHTML = "&nbsp;&nbsp;&nbsp;"; blankCell.innerHTML = "&nbsp;&nbsp;&nbsp;";
eventWrapper.appendChild(blankCell); eventWrapper.appendChild(blankCell);
@ -261,7 +260,7 @@ Module.register("calendar", {
titleWrapper.colSpan = "2"; titleWrapper.colSpan = "2";
titleWrapper.align = "left"; titleWrapper.align = "left";
}else{ } else {
var timeClass = this.timeClassForUrl(event.url); var timeClass = this.timeClassForUrl(event.url);
var timeWrapper = document.createElement("td"); var timeWrapper = document.createElement("td");
@ -274,7 +273,7 @@ Module.register("calendar", {
} }
eventWrapper.appendChild(titleWrapper); eventWrapper.appendChild(titleWrapper);
}else{ } else {
var timeWrapper = document.createElement("td"); var timeWrapper = document.createElement("td");
eventWrapper.appendChild(titleWrapper); eventWrapper.appendChild(titleWrapper);
@ -499,7 +498,7 @@ Module.register("calendar", {
var midnight = moment(event.startDate, "x").clone().startOf("day").add(1, "day").format("x"); var midnight = moment(event.startDate, "x").clone().startOf("day").add(1, "day").format("x");
var count = 1; var count = 1;
while (event.endDate > midnight) { while (event.endDate > midnight) {
var thisEvent = JSON.parse(JSON.stringify(event)) // clone object var thisEvent = JSON.parse(JSON.stringify(event)); // clone object
thisEvent.today = thisEvent.startDate >= today && thisEvent.startDate < (today + 24 * 60 * 60 * 1000); thisEvent.today = thisEvent.startDate >= today && thisEvent.startDate < (today + 24 * 60 * 60 * 1000);
thisEvent.endDate = midnight; thisEvent.endDate = midnight;
thisEvent.title += " (" + count + "/" + maxCount + ")"; thisEvent.title += " (" + count + "/" + maxCount + ")";
@ -530,7 +529,6 @@ Module.register("calendar", {
return events.slice(0, this.config.maximumEntries); return events.slice(0, this.config.maximumEntries);
}, },
listContainsEvent: function(eventList, event){ listContainsEvent: function(eventList, event){
for(var evt of eventList){ for(var evt of eventList){
if(evt.title === event.title && parseInt(evt.startDate) === parseInt(event.startDate)){ if(evt.title === event.title && parseInt(evt.startDate) === parseInt(event.startDate)){
@ -538,7 +536,6 @@ Module.register("calendar", {
} }
} }
return false; return false;
}, },
/* createEventList(url) /* createEventList(url)
@ -718,7 +715,6 @@ Module.register("calendar", {
* Capitalize the first letter of a string * Capitalize the first letter of a string
* Return capitalized string * Return capitalized string
*/ */
capFirst: function (string) { capFirst: function (string) {
return string.charAt(0).toUpperCase() + string.slice(1); return string.charAt(0).toUpperCase() + string.slice(1);
}, },

View File

@ -37,9 +37,9 @@ var CalendarFetcher = function(url, reloadInterval, excludedEvents, maximumEntri
if(auth.method === "bearer"){ if(auth.method === "bearer"){
opts.auth = { opts.auth = {
bearer: auth.pass bearer: auth.pass
} };
}else{ } else {
opts.auth = { opts.auth = {
user: auth.user, user: auth.user,
pass: auth.pass pass: auth.pass
@ -47,7 +47,7 @@ var CalendarFetcher = function(url, reloadInterval, excludedEvents, maximumEntri
if(auth.method === "digest"){ if(auth.method === "digest"){
opts.auth.sendImmediately = false; opts.auth.sendImmediately = false;
}else{ } else {
opts.auth.sendImmediately = true; opts.auth.sendImmediately = true;
} }
} }
@ -107,7 +107,6 @@ var CalendarFetcher = function(url, reloadInterval, excludedEvents, maximumEntri
} }
} }
// calculate the duration f the event for use with recurring events. // calculate the duration f the event for use with recurring events.
var duration = parseInt(endDate.format("x")) - parseInt(startDate.format("x")); var duration = parseInt(endDate.format("x")) - parseInt(startDate.format("x"));
@ -176,7 +175,7 @@ var CalendarFetcher = function(url, reloadInterval, excludedEvents, maximumEntri
var geo = event.geo || false; var geo = event.geo || false;
var description = event.description || false; var description = event.description || false;
if (typeof event.rrule != "undefined" && event.rrule != null && !isFacebookBirthday) { if (typeof event.rrule !== undefined && event.rrule !== null && !isFacebookBirthday) {
var rule = event.rrule; var rule = event.rrule;
// can cause problems with e.g. birthdays before 1900 // can cause problems with e.g. birthdays before 1900
@ -341,7 +340,7 @@ var CalendarFetcher = function(url, reloadInterval, excludedEvents, maximumEntri
} else { } else {
return title.includes(filter); return title.includes(filter);
} }
} };
/* public methods */ /* public methods */
@ -395,8 +394,6 @@ var CalendarFetcher = function(url, reloadInterval, excludedEvents, maximumEntri
this.events = function() { this.events = function() {
return events; return events;
}; };
}; };
module.exports = CalendarFetcher; module.exports = CalendarFetcher;

View File

@ -214,7 +214,7 @@ vows.describe('node-ical').addBatch({
, 'event with rrule' :{ , 'event with rrule' :{
topic: function(events){ topic: function(events){
return _.select(_.values(events), function(x){ return _.select(_.values(events), function(x){
return x.summary == "foobarTV broadcast starts" return x.summary === "foobarTV broadcast starts"
})[0]; })[0];
} }
, "Has an RRULE": function(topic){ , "Has an RRULE": function(topic){

View File

@ -79,12 +79,12 @@ Module.register("clock",{
var timeWrapper = document.createElement("div"); var timeWrapper = document.createElement("div");
var secondsWrapper = document.createElement("sup"); var secondsWrapper = document.createElement("sup");
var periodWrapper = document.createElement("span"); var periodWrapper = document.createElement("span");
var weekWrapper = document.createElement("div") var weekWrapper = document.createElement("div");
// Style Wrappers // Style Wrappers
dateWrapper.className = "date normal medium"; dateWrapper.className = "date normal medium";
timeWrapper.className = "time bright large light"; timeWrapper.className = "time bright large light";
secondsWrapper.className = "dimmed"; secondsWrapper.className = "dimmed";
weekWrapper.className = "week dimmed medium" weekWrapper.className = "week dimmed medium";
// Set content of wrappers. // Set content of wrappers.
// The moment().format("h") method has a bug on the Raspberry Pi. // The moment().format("h") method has a bug on the Raspberry Pi.
@ -150,7 +150,7 @@ Module.register("clock",{
clockCircle.style.width = this.config.analogSize; clockCircle.style.width = this.config.analogSize;
clockCircle.style.height = this.config.analogSize; clockCircle.style.height = this.config.analogSize;
if (this.config.analogFace != "" && this.config.analogFace != "simple" && this.config.analogFace != "none") { if (this.config.analogFace !== "" && this.config.analogFace !== "simple" && this.config.analogFace !== "none") {
clockCircle.style.background = "url("+ this.data.path + "faces/" + this.config.analogFace + ".svg)"; clockCircle.style.background = "url("+ this.data.path + "faces/" + this.config.analogFace + ".svg)";
clockCircle.style.backgroundSize = "100%"; clockCircle.style.backgroundSize = "100%";
@ -158,7 +158,7 @@ Module.register("clock",{
// clockCircle.style.border = "1px solid black"; // clockCircle.style.border = "1px solid black";
clockCircle.style.border = "rgba(0, 0, 0, 0.1)"; //Updated fix for Issue 611 where non-black backgrounds are used clockCircle.style.border = "rgba(0, 0, 0, 0.1)"; //Updated fix for Issue 611 where non-black backgrounds are used
} else if (this.config.analogFace != "none") { } else if (this.config.analogFace !== "none") {
clockCircle.style.border = "2px solid white"; clockCircle.style.border = "2px solid white";
} }
var clockFace = document.createElement("div"); var clockFace = document.createElement("div");

View File

@ -54,7 +54,7 @@ Module.register("compliments", {
this.lastComplimentIndex = -1; this.lastComplimentIndex = -1;
var self = this; var self = this;
if (this.config.remoteFile != null) { if (this.config.remoteFile !== null) {
this.complimentFile(function(response) { this.complimentFile(function(response) {
self.config.compliments = JSON.parse(response); self.config.compliments = JSON.parse(response);
self.updateDom(); self.updateDom();
@ -134,7 +134,7 @@ Module.register("compliments", {
xobj.overrideMimeType("application/json"); xobj.overrideMimeType("application/json");
xobj.open("GET", path, true); xobj.open("GET", path, true);
xobj.onreadystatechange = function() { xobj.onreadystatechange = function() {
if (xobj.readyState == 4 && xobj.status == "200") { if (xobj.readyState === 4 && xobj.status === 200) {
callback(xobj.responseText); callback(xobj.responseText);
} }
}; };
@ -165,7 +165,6 @@ Module.register("compliments", {
return wrapper; return wrapper;
}, },
// From data currentweather set weather type // From data currentweather set weather type
setCurrentWeatherType: function(data) { setCurrentWeatherType: function(data) {
var weatherIconTable = { var weatherIconTable = {
@ -191,10 +190,9 @@ Module.register("compliments", {
this.currentWeatherType = weatherIconTable[data.weather[0].icon]; this.currentWeatherType = weatherIconTable[data.weather[0].icon];
}, },
// Override notification handler. // Override notification handler.
notificationReceived: function(notification, payload, sender) { notificationReceived: function(notification, payload, sender) {
if (notification == "CURRENTWEATHER_DATA") { if (notification === "CURRENTWEATHER_DATA") {
this.setCurrentWeatherType(payload.data); this.setCurrentWeatherType(payload.data);
} }
}, },

View File

@ -353,7 +353,7 @@ Module.register("currentweather",{
} else if(this.config.location) { } else if(this.config.location) {
params += "q=" + this.config.location; params += "q=" + this.config.location;
} else if (this.firstEvent && this.firstEvent.geo) { } else if (this.firstEvent && this.firstEvent.geo) {
params += "lat=" + this.firstEvent.geo.lat + "&lon=" + this.firstEvent.geo.lon params += "lat=" + this.firstEvent.geo.lat + "&lon=" + this.firstEvent.geo.lon;
} else if (this.firstEvent && this.firstEvent.location) { } else if (this.firstEvent && this.firstEvent.location) {
params += "q=" + this.firstEvent.location; params += "q=" + this.firstEvent.location;
} else { } else {

View File

@ -15,10 +15,10 @@ Module.register("helloworld",{
}, },
getTemplate: function () { getTemplate: function () {
return "helloworld.njk" return "helloworld.njk";
}, },
getTemplateData: function () { getTemplateData: function () {
return this.config return this.config;
} }
}); });

View File

@ -81,11 +81,10 @@ var Fetcher = function(url, reloadInterval, encoding, logFeedWarnings) {
scheduleTimer(); scheduleTimer();
}); });
nodeVersion = Number(process.version.match(/^v(\d+\.\d+)/)[1]); nodeVersion = Number(process.version.match(/^v(\d+\.\d+)/)[1]);
headers = {"User-Agent": "Mozilla/5.0 (Node.js "+ nodeVersion + ") MagicMirror/" + global.version + " (https://github.com/MichMich/MagicMirror/)", headers = {"User-Agent": "Mozilla/5.0 (Node.js "+ nodeVersion + ") MagicMirror/" + global.version + " (https://github.com/MichMich/MagicMirror/)",
"Cache-Control": "max-age=0, no-cache, no-store, must-revalidate", "Cache-Control": "max-age=0, no-cache, no-store, must-revalidate",
"Pragma": "no-cache"} "Pragma": "no-cache"};
request({uri: url, encoding: null, headers: headers}) request({uri: url, encoding: null, headers: headers})
.on("error", function(error) { .on("error", function(error) {

View File

@ -191,7 +191,7 @@ Module.register("newsfeed",{
fullArticle.style.top = "0"; fullArticle.style.top = "0";
fullArticle.style.left = "0"; fullArticle.style.left = "0";
fullArticle.style.border = "none"; fullArticle.style.border = "none";
fullArticle.src = this.getActiveItemURL() fullArticle.src = this.getActiveItemURL();
fullArticle.style.zIndex = 1; fullArticle.style.zIndex = 1;
wrapper.appendChild(fullArticle); wrapper.appendChild(fullArticle);
} }
@ -419,7 +419,7 @@ Module.register("newsfeed",{
date: this.newsItems[this.activeItem].pubdate, date: this.newsItems[this.activeItem].pubdate,
desc: this.newsItems[this.activeItem].description, desc: this.newsItems[this.activeItem].description,
url: this.getActiveItemURL() url: this.getActiveItemURL()
}) });
} else { } else {
Log.info(this.name + " - unknown notification, ignoring: " + notification); Log.info(this.name + " - unknown notification, ignoring: " + notification);
} }

View File

@ -79,7 +79,7 @@ module.exports = NodeHelper.create({
scheduleNextFetch: function(delay) { scheduleNextFetch: function(delay) {
if (delay < 60 * 1000) { if (delay < 60 * 1000) {
delay = 60 * 1000 delay = 60 * 1000;
} }
var self = this; var self = this;

View File

@ -8,7 +8,6 @@ Module.register("updatenotification", {
start: function () { start: function () {
Log.log("Start updatenotification"); Log.log("Start updatenotification");
}, },
notificationReceived: function (notification, payload, sender) { notificationReceived: function (notification, payload, sender) {
@ -58,14 +57,14 @@ Module.register("updatenotification", {
icon.innerHTML = "&nbsp;"; icon.innerHTML = "&nbsp;";
message.appendChild(icon); message.appendChild(icon);
var updateInfoKeyName = this.status.behind == 1 ? "UPDATE_INFO_SINGLE" : "UPDATE_INFO_MULTIPLE"; var updateInfoKeyName = this.status.behind === 1 ? "UPDATE_INFO_SINGLE" : "UPDATE_INFO_MULTIPLE";
var subtextHtml = this.translate(updateInfoKeyName, { var subtextHtml = this.translate(updateInfoKeyName, {
COMMIT_COUNT: this.status.behind, COMMIT_COUNT: this.status.behind,
BRANCH_NAME: this.status.current BRANCH_NAME: this.status.current
}); });
var text = document.createElement("span"); var text = document.createElement("span");
if (this.status.module == "default") { if (this.status.module === "default") {
text.innerHTML = this.translate("UPDATE_NOTIFICATION"); text.innerHTML = this.translate("UPDATE_NOTIFICATION");
subtextHtml = this.diffLink(subtextHtml); subtextHtml = this.diffLink(subtextHtml);
} else { } else {

View File

@ -24,7 +24,7 @@
{% endif %} {% endif %}
<span class="wi dimmed wi-{{ current.nextSunAction() }}"></span> <span class="wi dimmed wi-{{ current.nextSunAction() }}"></span>
<span> <span>
{% if current.nextSunAction() == "sunset" %} {% if current.nextSunAction() === "sunset" %}
{{ current.sunset | formatTime }} {{ current.sunset | formatTime }}
{% else %} {% else %}
{{ current.sunrise | formatTime }} {{ current.sunrise | formatTime }}

View File

@ -86,9 +86,9 @@ WeatherProvider.register("openweathermap", {
*/ */
generateWeatherObjectsFromForecast(forecasts) { generateWeatherObjectsFromForecast(forecasts) {
if (this.config.weatherEndpoint == "/forecast") { if (this.config.weatherEndpoint === "/forecast") {
return this.fetchForecastHourly(forecasts); return this.fetchForecastHourly(forecasts);
} else if (this.config.weatherEndpoint == "/forecast/daily") { } else if (this.config.weatherEndpoint === "/forecast/daily") {
return this.fetchForecastDaily(forecasts); return this.fetchForecastDaily(forecasts);
} }
// if weatherEndpoint does not match forecast or forecast/daily, what should be returned? // if weatherEndpoint does not match forecast or forecast/daily, what should be returned?

View File

@ -143,7 +143,7 @@ Module.register("weather",{
humidity: this.indoorHumidity, humidity: this.indoorHumidity,
temperature: this.indoorTemperature temperature: this.indoorTemperature
} }
} };
}, },
// What to do when the weather provider has new information available? // What to do when the weather provider has new information available?
@ -217,7 +217,7 @@ Module.register("weather",{
} }
} }
} else if (type === "humidity") { } else if (type === "humidity") {
value += "%" value += "%";
} }
return value; return value;

View File

@ -9,7 +9,6 @@
* This class is the blueprint for a weather provider. * This class is the blueprint for a weather provider.
*/ */
/** /**
* Base BluePrint for the WeatherProvider * Base BluePrint for the WeatherProvider
*/ */
@ -23,15 +22,14 @@ var WeatherProvider = Class.extend({
weatherForecastArray: null, weatherForecastArray: null,
fetchedLocationName: null, fetchedLocationName: null,
// The following properties will be set automaticly. // The following properties will be set automatically.
// You do not need to overwrite these properties. // You do not need to overwrite these properties.
config: null, config: null,
delegate: null, delegate: null,
providerIdentifier: null, providerIdentifier: null,
// Weather Provider Methods // Weather Provider Methods
// All the following methods can be overwrited, although most are good as they are. // All the following methods can be overwritten, although most are good as they are.
// Called when a weather provider is initialized. // Called when a weather provider is initialized.
init: function(config) { init: function(config) {
@ -51,13 +49,13 @@ var WeatherProvider = Class.extend({
}, },
// This method should start the API request to fetch the current weather. // This method should start the API request to fetch the current weather.
// This method should definetly be overwritten in the provider. // This method should definitely be overwritten in the provider.
fetchCurrentWeather: function() { fetchCurrentWeather: function() {
Log.warn(`Weather provider: ${this.providerName} does not subclass the fetchCurrentWeather method.`); Log.warn(`Weather provider: ${this.providerName} does not subclass the fetchCurrentWeather method.`);
}, },
// This method should start the API request to fetch the weather forecast. // This method should start the API request to fetch the weather forecast.
// This method should definetly be overwritten in the provider. // This method should definitely be overwritten in the provider.
fetchWeatherForecast: function() { fetchWeatherForecast: function() {
Log.warn(`Weather provider: ${this.providerName} does not subclass the fetchWeatherForecast method.`); Log.warn(`Weather provider: ${this.providerName} does not subclass the fetchWeatherForecast method.`);
}, },
@ -103,7 +101,7 @@ var WeatherProvider = Class.extend({
this.delegate.updateAvailable(this); this.delegate.updateAvailable(this);
}, },
// A convinience function to make requests. It returns a promise. // A convenience function to make requests. It returns a promise.
fetchData: function(url, method = "GET", data = null) { fetchData: function(url, method = "GET", data = null) {
return new Promise(function(resolve, reject) { return new Promise(function(resolve, reject) {
var request = new XMLHttpRequest(); var request = new XMLHttpRequest();
@ -113,12 +111,12 @@ var WeatherProvider = Class.extend({
if (this.status === 200) { if (this.status === 200) {
resolve(JSON.parse(this.response)); resolve(JSON.parse(this.response));
} else { } else {
reject(request) reject(request);
} }
} }
}; };
request.send(); request.send();
}) });
} }
}); });

View File

@ -19,9 +19,9 @@
} }
.weatherforecast tr.colored .min-temp { .weatherforecast tr.colored .min-temp {
color: #BCDDFF; color: #BCDDFF;
} }
.weatherforecast tr.colored .max-temp { .weatherforecast tr.colored .max-temp {
color: #FF8E99; color: #FF8E99;
} }

View File

@ -82,7 +82,7 @@ Module.register("weatherforecast",{
getTranslations: function() { getTranslations: function() {
// The translations for the default modules are defined in the core translation files. // The translations for the default modules are defined in the core translation files.
// Therefor we can just return false. Otherwise we should have returned a dictionary. // Therefor we can just return false. Otherwise we should have returned a dictionary.
// If you're trying to build yiur own module including translations, check out the documentation. // If you're trying to build your own module including translations, check out the documentation.
return false; return false;
}, },
@ -240,7 +240,7 @@ Module.register("weatherforecast",{
/* updateWeather(compliments) /* updateWeather(compliments)
* Requests new data from openweather.org. * Requests new data from openweather.org.
* Calls processWeather on succesfull response. * Calls processWeather on successful response.
*/ */
updateWeather: function() { updateWeather: function() {
if (this.config.appid === "") { if (this.config.appid === "") {
@ -261,7 +261,7 @@ Module.register("weatherforecast",{
} else if (this.status === 401) { } else if (this.status === 401) {
self.updateDom(self.config.animationSpeed); self.updateDom(self.config.animationSpeed);
if (self.config.forecastEndpoint == "forecast/daily") { if (self.config.forecastEndpoint === "forecast/daily") {
self.config.forecastEndpoint = "forecast"; self.config.forecastEndpoint = "forecast";
Log.warn(self.name + ": Your AppID does not support long term forecasts. Switching to fallback endpoint."); Log.warn(self.name + ": Your AppID does not support long term forecasts. Switching to fallback endpoint.");
} }
@ -291,7 +291,7 @@ Module.register("weatherforecast",{
} else if(this.config.location) { } else if(this.config.location) {
params += "q=" + this.config.location; params += "q=" + this.config.location;
} else if (this.firstEvent && this.firstEvent.geo) { } else if (this.firstEvent && this.firstEvent.geo) {
params += "lat=" + this.firstEvent.geo.lat + "&lon=" + this.firstEvent.geo.lon params += "lat=" + this.firstEvent.geo.lat + "&lon=" + this.firstEvent.geo.lon;
} else if (this.firstEvent && this.firstEvent.location) { } else if (this.firstEvent && this.firstEvent.location) {
params += "q=" + this.firstEvent.location; params += "q=" + this.firstEvent.location;
} else { } else {
@ -315,7 +315,7 @@ Module.register("weatherforecast",{
*/ */
parserDataWeather: function(data) { parserDataWeather: function(data) {
if (data.hasOwnProperty("main")) { if (data.hasOwnProperty("main")) {
data["temp"] = {"min": data.main.temp_min, "max": data.main.temp_max} data["temp"] = {"min": data.main.temp_min, "max": data.main.temp_max};
} }
return data; return data;
}, },
@ -330,7 +330,7 @@ Module.register("weatherforecast",{
this.forecast = []; this.forecast = [];
var lastDay = null; var lastDay = null;
var forecastData = {} var forecastData = {};
for (var i = 0, count = data.list.length; i < count; i++) { for (var i = 0, count = data.list.length; i < count; i++) {

4475
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -41,7 +41,7 @@
"grunt": "latest", "grunt": "latest",
"grunt-eslint": "latest", "grunt-eslint": "latest",
"grunt-jsonlint": "latest", "grunt-jsonlint": "latest",
"grunt-markdownlint": "^1.0.43", "grunt-markdownlint": "latest",
"grunt-stylelint": "latest", "grunt-stylelint": "latest",
"grunt-yamllint": "latest", "grunt-yamllint": "latest",
"http-auth": "^3.2.3", "http-auth": "^3.2.3",
@ -49,29 +49,25 @@
"jshint": "^2.10.2", "jshint": "^2.10.2",
"mocha": "^4.1.0", "mocha": "^4.1.0",
"mocha-each": "^1.1.0", "mocha-each": "^1.1.0",
"mocha-logger": "^1.0.6",
"spectron": "^3.8.0", "spectron": "^3.8.0",
"stylelint": "^9.10.1", "stylelint": "latest",
"stylelint-config-standard": "latest", "stylelint-config-standard": "latest",
"time-grunt": "latest" "time-grunt": "latest"
}, },
"dependencies": { "dependencies": {
"ajv": "6.5.5",
"body-parser": "^1.18.2",
"colors": "^1.1.2", "colors": "^1.1.2",
"electron": "^3.0.13", "electron": "^3.0.13",
"express": "^4.16.2", "express": "^4.16.2",
"express-ipfilter": "0.3.1", "express-ipfilter": "^1.0.1",
"feedme": "latest", "feedme": "latest",
"helmet": "^3.9.0", "helmet": "^3.9.0",
"home-path": "^1.0.6",
"iconv-lite": "latest", "iconv-lite": "latest",
"mocha-logger": "^1.0.6",
"moment": "latest", "moment": "latest",
"request": "^2.87.0", "request": "^2.87.0",
"rrule-alt": "^2.2.8", "rrule-alt": "^2.2.8",
"simple-git": "^1.85.0", "simple-git": "^1.85.0",
"socket.io": "^2.1.1", "socket.io": "^2.1.1",
"valid-url": "latest", "valid-url": "latest"
"walk": "latest"
} }
} }

View File

@ -16,7 +16,7 @@ var Utils = require(__dirname + "/../../js/utils.js");
/* getConfigFile() /* getConfigFile()
* Return string with path of configuration file * 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() { function getConfigFile() {
// FIXME: This function should be in core. Do you want refactor me ;) ?, be good! // 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); console.error(Utils.colors.error("File not found: "), configFileName);
return; return;
} }
// check permision // check permission
try { try {
fs.accessSync(configFileName, fs.F_OK); fs.accessSync(configFileName, fs.F_OK);
} catch (e) { } catch (e) {
@ -52,12 +52,12 @@ function checkConfigFile() {
if (err) { throw err; } if (err) { throw err; }
v.JSHINT(data); // Parser by jshint 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 :)"); console.log("Your configuration file doesn't contain syntax errors :)");
return true; return true;
} else { } else {
errors = v.JSHINT.data().errors; errors = v.JSHINT.data().errors;
for (idx in errors) { for (var idx in errors) {
error = errors[idx]; error = errors[idx];
console.log("Line", error.line, "col", error.character, error.reason); console.log("Line", error.line, "col", error.character, error.reason);
} }
@ -67,4 +67,4 @@ function checkConfigFile() {
if (process.env.NODE_ENV !== "test") { if (process.env.NODE_ENV !== "test") {
checkConfigFile(); 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 * By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed. * MIT Licensed.

View File

@ -6,7 +6,6 @@
* MIT Licensed. * MIT Licensed.
*/ */
var config = { var config = {
port: 8080, port: 8080,
ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], 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 * By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed. * MIT Licensed.

View File

@ -1,13 +1,8 @@
const helpers = require("./global-setup"); const helpers = require("./global-setup");
const path = require("path");
const request = require("request");
const expect = require("chai").expect; const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
const it = global.it; const it = global.it;
const beforeEach = global.beforeEach;
const afterEach = global.afterEach;
describe("Development console tests", function() { describe("Development console tests", function() {
// This tests fail and crash another tests // This tests fail and crash another tests

View File

@ -1,7 +1,5 @@
const helpers = require("./global-setup"); const helpers = require("./global-setup");
const path = require("path");
const request = require("request"); const request = require("request");
const expect = require("chai").expect; const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;

View File

@ -1,14 +1,9 @@
const helpers = require("./global-setup"); const helpers = require("./global-setup");
const path = require("path");
const request = require("request"); const request = require("request");
const expect = require("chai").expect; const expect = require("chai").expect;
const forEach = require("mocha-each");
const describe = global.describe; const describe = global.describe;
const it = global.it;
const beforeEach = global.beforeEach;
const afterEach = global.afterEach;
const forEach = require("mocha-each");
describe("All font files from roboto.css should be downloadable", function() { describe("All font files from roboto.css should be downloadable", function() {
helpers.setupTimeout(this); helpers.setupTimeout(this);
@ -18,7 +13,7 @@ describe("All font files from roboto.css should be downloadable", function() {
var fileContent = require("fs").readFileSync(__dirname + "/../../fonts/roboto.css", "utf8"); var fileContent = require("fs").readFileSync(__dirname + "/../../fonts/roboto.css", "utf8");
var regex = /\burl\(['"]([^'"]+)['"]\)/g; var regex = /\burl\(['"]([^'"]+)['"]\)/g;
var match = regex.exec(fileContent); var match = regex.exec(fileContent);
while (match != null) { while (match !== null) {
// Push 1st match group onto fontFiles stack // Push 1st match group onto fontFiles stack
fontFiles.push(match[1]); fontFiles.push(match[1]);
// Find the next one // Find the next one

View File

@ -12,7 +12,6 @@ const Application = require("spectron").Application;
const assert = require("assert"); const assert = require("assert");
const chai = require("chai"); const chai = require("chai");
const chaiAsPromised = require("chai-as-promised"); const chaiAsPromised = require("chai-as-promised");
const path = require("path"); const path = require("path");
global.before(function() { global.before(function() {

View File

@ -1,7 +1,5 @@
const helpers = require("./global-setup"); const helpers = require("./global-setup");
const path = require("path");
const request = require("request"); const request = require("request");
const expect = require("chai").expect; const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
@ -17,7 +15,7 @@ describe("ipWhitelist directive configuration", function () {
beforeEach(function () { beforeEach(function () {
return helpers.startApplication({ return helpers.startApplication({
args: ["js/electron.js"] args: ["js/electron.js"]
}).then(function (startedApp) { app = startedApp; }) }).then(function (startedApp) { app = startedApp; });
}); });
afterEach(function () { afterEach(function () {

View File

@ -1,10 +1,6 @@
const helpers = require("../global-setup"); const helpers = require("../global-setup");
const path = require("path");
const request = require("request");
const serverBasicAuth = require("../../servers/basic-auth.js"); const serverBasicAuth = require("../../servers/basic-auth.js");
const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
const it = global.it; const it = global.it;
const beforeEach = global.beforeEach; const beforeEach = global.beforeEach;
@ -72,7 +68,7 @@ describe("Calendar module", function() {
}); });
}); });
describe("Basic auth backward compatibilty configuration: DEPRECATED", function() { describe("Basic auth backward compatibility configuration: DEPRECATED", function() {
before(function() { before(function() {
serverBasicAuth.listen(8012); serverBasicAuth.listen(8012);
// Set config sample for use in test // Set config sample for use in test

View File

@ -1,8 +1,4 @@
const helpers = require("../global-setup"); const helpers = require("../global-setup");
const path = require("path");
const request = require("request");
const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
const it = global.it; const it = global.it;
@ -86,5 +82,4 @@ describe("Clock set to spanish language module", function() {
.getText(".clock .week").should.eventually.match(weekRegex); .getText(".clock .week").should.eventually.match(weekRegex);
}); });
}); });
}); });

View File

@ -1,8 +1,4 @@
const helpers = require("../global-setup"); const helpers = require("../global-setup");
const path = require("path");
const request = require("request");
const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
const it = global.it; const it = global.it;

View File

@ -1,7 +1,4 @@
const helpers = require("../global-setup"); const helpers = require("../global-setup");
const path = require("path");
const request = require("request");
const expect = require("chai").expect; const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;

View File

@ -1,8 +1,4 @@
const helpers = require("../global-setup"); const helpers = require("../global-setup");
const path = require("path");
const request = require("request");
const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
const it = global.it; const it = global.it;
@ -24,7 +20,6 @@ describe("Test helloworld module", function() {
}); });
}); });
afterEach(function() { afterEach(function() {
return helpers.stopApplication(app); return helpers.stopApplication(app);
}); });
@ -52,5 +47,4 @@ describe("Test helloworld module", function() {
.getText(".helloworld").should.eventually.equal("Hello World!"); .getText(".helloworld").should.eventually.equal("Hello World!");
}); });
}); });
}); });

View File

@ -1,8 +1,4 @@
const helpers = require("../global-setup"); const helpers = require("../global-setup");
const path = require("path");
const request = require("request");
const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
const it = global.it; const it = global.it;

View File

@ -1,13 +1,7 @@
const helpers = require("./global-setup"); const helpers = require("./global-setup");
const path = require("path");
const request = require("request");
const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
const it = global.it; const it = global.it;
const beforeEach = global.beforeEach;
const afterEach = global.afterEach;
describe("Position of modules", function () { describe("Position of modules", function () {
helpers.setupTimeout(this); helpers.setupTimeout(this);
@ -25,8 +19,7 @@ describe("Position of modules", function () {
process.env.MM_CONFIG_FILE = "tests/configs/modules/positions.js"; process.env.MM_CONFIG_FILE = "tests/configs/modules/positions.js";
return helpers.startApplication({ return helpers.startApplication({
args: ["js/electron.js"] args: ["js/electron.js"]
}).then(function (startedApp) { app = startedApp; }) }).then(function (startedApp) { app = startedApp; });
}); });
var positions = ["top_bar", "top_left", "top_center", "top_right", "upper_third", var positions = ["top_bar", "top_left", "top_center", "top_right", "upper_third",
@ -44,5 +37,4 @@ describe("Position of modules", function () {
}); });
} }
}); });
}); });

View File

@ -1,7 +1,5 @@
const helpers = require("./global-setup"); const helpers = require("./global-setup");
const path = require("path");
const request = require("request"); const request = require("request");
const expect = require("chai").expect; const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
@ -17,7 +15,7 @@ describe("port directive configuration", function () {
beforeEach(function () { beforeEach(function () {
return helpers.startApplication({ return helpers.startApplication({
args: ["js/electron.js"] args: ["js/electron.js"]
}).then(function (startedApp) { app = startedApp; }) }).then(function (startedApp) { app = startedApp; });
}); });
afterEach(function () { afterEach(function () {
@ -38,7 +36,7 @@ describe("port directive configuration", function () {
}); });
}); });
describe("Set port 8100 on enviroment variable MM_PORT", function () { describe("Set port 8100 on environment variable MM_PORT", function () {
before(function () { before(function () {
process.env.MM_PORT = 8100; process.env.MM_PORT = 8100;
// Set config sample for use in this test // Set config sample for use in this test
@ -56,5 +54,4 @@ describe("port directive configuration", function () {
}); });
}); });
}); });
}); });

View File

@ -121,8 +121,7 @@ describe("Translations", function() {
throw e; throw e;
} }
} }
}) });
}); });
} }
}); });

View File

@ -1,7 +1,5 @@
const helpers = require("./global-setup"); const helpers = require("./global-setup");
const path = require("path");
const request = require("request"); const request = require("request");
const expect = require("chai").expect; const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
@ -20,7 +18,7 @@ describe("Vendors", function () {
before(function () { before(function () {
return helpers.startApplication({ return helpers.startApplication({
args: ["js/electron.js"] args: ["js/electron.js"]
}).then(function (startedApp) { app = startedApp; }) }).then(function (startedApp) { app = startedApp; });
}); });
after(function () { after(function () {

View File

@ -1,8 +1,4 @@
const helpers = require("./global-setup"); const helpers = require("./global-setup");
const path = require("path");
const request = require("request");
const expect = require("chai").expect;
const describe = global.describe; const describe = global.describe;
const it = global.it; const it = global.it;
@ -17,7 +13,7 @@ describe("Check configuration without modules", function () {
beforeEach(function () { beforeEach(function () {
return helpers.startApplication({ return helpers.startApplication({
args: ["js/electron.js"] args: ["js/electron.js"]
}).then(function (startedApp) { app = startedApp; }) }).then(function (startedApp) { app = startedApp; });
}); });
afterEach(function () { afterEach(function () {
@ -31,13 +27,12 @@ describe("Check configuration without modules", function () {
it("Show the message MagicMirror title", function () { it("Show the message MagicMirror title", function () {
return app.client.waitUntilWindowLoaded() return app.client.waitUntilWindowLoaded()
.getText("#module_1_helloworld .module-content").should.eventually.equal("Magic Mirror2") .getText("#module_1_helloworld .module-content").should.eventually.equal("Magic Mirror2");
}); });
it("Show the text Michael's website", function () { it("Show the text Michael's website", function () {
return app.client.waitUntilWindowLoaded() return app.client.waitUntilWindowLoaded()
.getText("#module_5_helloworld .module-content").should.eventually.equal("www.michaelteeuw.nl"); .getText("#module_5_helloworld .module-content").should.eventually.equal("www.michaelteeuw.nl");
}); });
}); });

View File

@ -1,4 +1,3 @@
var http = require("http");
var path = require("path"); var path = require("path");
var auth = require("http-auth"); var auth = require("http-auth");
var express = require("express"); var express = require("express");
@ -17,11 +16,11 @@ var basic = auth.basic(
app.use(auth.connect(basic)); app.use(auth.connect(basic));
// Set directories availables // Set available directories
var directories = ["/tests/configs"]; var directories = ["/tests/configs"];
var directory; var directory;
rootPath = path.resolve(__dirname + "/../../"); rootPath = path.resolve(__dirname + "/../../");
for (i in directories) { for (var i in directories) {
directory = directories[i]; directory = directories[i];
app.use(directory, express.static(path.resolve(rootPath + directory))); app.use(directory, express.static(path.resolve(rootPath + directory)));
} }

View File

@ -1,5 +1,4 @@
const chai = require("chai"); const expect = require("chai").expect;
const expect = chai.expect;
const path = require("path"); const path = require("path");
const {JSDOM} = require("jsdom"); const {JSDOM} = require("jsdom");

View File

@ -1,5 +1,4 @@
const chai = require("chai"); const expect = require("chai").expect;
const expect = chai.expect;
const deprecated = require("../../../js/deprecated"); const deprecated = require("../../../js/deprecated");
describe("Deprecated", function() { describe("Deprecated", function() {

View File

@ -1,7 +1,5 @@
const chai = require("chai"); const expect = require("chai").expect;
const expect = chai.expect;
const path = require("path"); const path = require("path");
const fs = require("fs");
const helmet = require("helmet"); const helmet = require("helmet");
const {JSDOM} = require("jsdom"); const {JSDOM} = require("jsdom");
const express = require("express"); const express = require("express");

View File

@ -1,5 +1,4 @@
var chai = require("chai"); var expect = require("chai").expect;
var expect = chai.expect;
var Utils = require("../../../js/utils.js"); var Utils = require("../../../js/utils.js");
var colors = require("colors/safe"); var colors = require("colors/safe");
@ -38,4 +37,3 @@ describe("Utils", function() {
}); });
}); });
}); });

View File

@ -5,7 +5,7 @@ global.moment = require("moment");
describe("Functions into modules/default/calendar/calendar.js", function() { describe("Functions into modules/default/calendar/calendar.js", function() {
// Fake for use by calendar.js // Fake for use by calendar.js
Module = {} Module = {};
Module.definitions = {}; Module.definitions = {};
Module.register = function (name, moduleDefinition) { Module.register = function (name, moduleDefinition) {
Module.definitions[name] = moduleDefinition; Module.definitions[name] = moduleDefinition;

View File

@ -1,5 +1,4 @@
const chai = require("chai"); const expect = require("chai").expect;
const expect = chai.expect;
const path = require("path"); const path = require("path");
const {JSDOM} = require("jsdom"); const {JSDOM} = require("jsdom");
@ -29,4 +28,3 @@ describe("Test function cmpVersions in js/module.js", function() {
expect(cmp("1.1", "1.0")).to.equal(1); expect(cmp("1.1", "1.0")).to.equal(1);
}); });
}); });

View File

@ -1,13 +1,7 @@
var fs = require("fs"); var expect = require("chai").expect;
var path = require("path");
var chai = require("chai");
var expect = chai.expect;
var vm = require("vm");
describe("Functions module currentweather", function() { describe("Functions module currentweather", function() {
// Fake for use by currentweather.js // Fake for use by currentweather.js
Module = {}; Module = {};
config = {}; config = {};
@ -16,7 +10,6 @@ describe("Functions module currentweather", function() {
Module.definitions[name] = moduleDefinition; Module.definitions[name] = moduleDefinition;
}; };
before(function(){ before(function(){
require("../../../modules/default/currentweather/currentweather.js"); require("../../../modules/default/currentweather/currentweather.js");
Module.definitions.currentweather.config = {}; Module.definitions.currentweather.config = {};
@ -39,7 +32,7 @@ describe("Functions module currentweather", function() {
[2.0 , "2"], [2.0 , "2"],
["2.12" , "2"], ["2.12" , "2"],
[10.1 , "10"] [10.1 , "10"]
] ];
values.forEach(value => { values.forEach(value => {
it(`for ${value[0]} should be return ${value[1]}`, function() { it(`for ${value[0]} should be return ${value[1]}`, function() {
@ -48,7 +41,6 @@ describe("Functions module currentweather", function() {
}); });
}); });
describe("this.config.roundTemp is false", function() { describe("this.config.roundTemp is false", function() {
before(function(){ before(function(){
@ -66,7 +58,7 @@ describe("Functions module currentweather", function() {
["2.12" , "2.1"], ["2.12" , "2.1"],
[10.1 , "10.1"], [10.1 , "10.1"],
[10.10 , "10.1"] [10.10 , "10.1"]
] ];
values.forEach(value => { values.forEach(value => {
it(`for ${value[0]} should be return ${value[1]}`, function() { it(`for ${value[0]} should be return ${value[1]}`, function() {

View File

@ -1,13 +1,8 @@
var fs = require("fs"); var expect = require("chai").expect;
var path = require("path");
var chai = require("chai");
var expect = chai.expect;
var vm = require("vm");
describe("Functions into modules/default/newsfeed/newsfeed.js", function() { describe("Functions into modules/default/newsfeed/newsfeed.js", function() {
Module = {} Module = {};
Module.definitions = {}; Module.definitions = {};
Module.register = function (name, moduleDefinition) { Module.register = function (name, moduleDefinition) {
Module.definitions[name] = moduleDefinition; Module.definitions[name] = moduleDefinition;
@ -32,6 +27,5 @@ describe("Functions into modules/default/newsfeed/newsfeed.js", function() {
}); });
}); });
}); });
}); });

View File

@ -1,9 +1,4 @@
var fs = require("fs"); var expect = require("chai").expect;
var path = require("path");
var chai = require("chai");
var expect = chai.expect;
var vm = require("vm");
describe("Functions module weatherforecast", function() { describe("Functions module weatherforecast", function() {
@ -35,7 +30,7 @@ describe("Functions module weatherforecast", function() {
[2.0 , "2"], [2.0 , "2"],
["2.12" , "2"], ["2.12" , "2"],
[10.1 , "10"] [10.1 , "10"]
] ];
values.forEach(value => { values.forEach(value => {
it(`for ${value[0]} should be return ${value[1]}`, function() { it(`for ${value[0]} should be return ${value[1]}`, function() {
@ -44,7 +39,6 @@ describe("Functions module weatherforecast", function() {
}); });
}); });
describe("this.config.roundTemp is false", function() { describe("this.config.roundTemp is false", function() {
before(function(){ before(function(){
@ -62,7 +56,7 @@ describe("Functions module weatherforecast", function() {
["2.12" , "2.1"], ["2.12" , "2.1"],
[10.1 , "10.1"], [10.1 , "10.1"],
[10.10 , "10.1"] [10.10 , "10.1"]
] ];
values.forEach(value => { values.forEach(value => {
it(`for ${value[0]} should be return ${value[1]}`, function() { it(`for ${value[0]} should be return ${value[1]}`, function() {

View File

@ -1,7 +1,6 @@
var fs = require("fs"); var fs = require("fs");
var path = require("path"); var path = require("path");
var chai = require("chai"); var expect = require("chai").expect;
var expect = chai.expect;
var vm = require("vm"); var vm = require("vm");
before(function() { before(function() {
@ -62,5 +61,4 @@ describe("Default modules set in modules/default/defaultmodules.js", function()
expect(fs.existsSync(path.join(this.sandbox.global.root_path, "modules/default", defaultModule))).to.equal(true); expect(fs.existsSync(path.join(this.sandbox.global.root_path, "modules/default", defaultModule))).to.equal(true);
}); });
}); });
}); });

View File

@ -1,7 +1,6 @@
var fs = require("fs"); var fs = require("fs");
var path = require("path"); var path = require("path");
var chai = require("chai"); var expect = require("chai").expect;
var expect = chai.expect;
var vm = require("vm"); var vm = require("vm");
before(function() { before(function() {
@ -66,6 +65,4 @@ describe("'global.root_path' set in js/app.js", function() {
versionPackage = JSON.parse(fs.readFileSync("package.json", "utf8")).version; versionPackage = JSON.parse(fs.readFileSync("package.json", "utf8")).version;
expect(this.sandbox.global.version).to.equal(versionPackage); expect(this.sandbox.global.version).to.equal(versionPackage);
}); });
}); });

View File

@ -25,7 +25,6 @@
"WNW": "VNV", "WNW": "VNV",
"NW": "NV", "NW": "NV",
"NNW": "NNV", "NNW": "NNV",
"FEELS": "Känns som",
"UPDATE_NOTIFICATION": "MagicMirror² uppdatering finns tillgänglig.", "UPDATE_NOTIFICATION": "MagicMirror² uppdatering finns tillgänglig.",
"UPDATE_NOTIFICATION_MODULE": "Uppdatering finns tillgänglig av {MODULE_NAME} modulen.", "UPDATE_NOTIFICATION_MODULE": "Uppdatering finns tillgänglig av {MODULE_NAME} modulen.",

View File

@ -45,4 +45,3 @@ var translations = {
if (typeof module !== "undefined") {module.exports = translations;} if (typeof module !== "undefined") {module.exports = translations;}

25
vendor/package-lock.json generated vendored
View File

@ -703,6 +703,7 @@
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-2.0.0.tgz", "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-2.0.0.tgz",
"integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=", "integrity": "sha1-gTg9ctsFT8zPUzbaqQLxgvbtuyg=",
"optional": true,
"requires": { "requires": {
"is-glob": "^2.0.0" "is-glob": "^2.0.0"
} }
@ -716,7 +717,8 @@
"inherits": { "inherits": {
"version": "2.0.3", "version": "2.0.3",
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz", "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.3.tgz",
"integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=" "integrity": "sha1-Yzwsg+PaQqUC9SRmAiSA9CCCYd4=",
"optional": true
}, },
"invert-kv": { "invert-kv": {
"version": "1.0.0", "version": "1.0.0",
@ -735,7 +737,8 @@
"is-buffer": { "is-buffer": {
"version": "1.1.5", "version": "1.1.5",
"resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.5.tgz", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.5.tgz",
"integrity": "sha1-Hzsm72E7IUuIy8ojzGwB2Hlh7sw=" "integrity": "sha1-Hzsm72E7IUuIy8ojzGwB2Hlh7sw=",
"optional": true
}, },
"is-dotfile": { "is-dotfile": {
"version": "1.0.3", "version": "1.0.3",
@ -761,7 +764,8 @@
"is-extglob": { "is-extglob": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-1.0.0.tgz",
"integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=" "integrity": "sha1-rEaBd8SUNAWgkvyPKXYMb/xiBsA=",
"optional": true
}, },
"is-fullwidth-code-point": { "is-fullwidth-code-point": {
"version": "1.0.0", "version": "1.0.0",
@ -775,6 +779,7 @@
"version": "2.0.1", "version": "2.0.1",
"resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz", "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-2.0.1.tgz",
"integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=", "integrity": "sha1-0Jb5JqPe1WAPP9/ZEZjLCIjC2GM=",
"optional": true,
"requires": { "requires": {
"is-extglob": "^1.0.0" "is-extglob": "^1.0.0"
} }
@ -803,7 +808,8 @@
"isarray": { "isarray": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz",
"integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=" "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=",
"optional": true
}, },
"isobject": { "isobject": {
"version": "2.1.0", "version": "2.1.0",
@ -818,6 +824,7 @@
"version": "3.2.2", "version": "3.2.2",
"resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz", "resolved": "https://registry.npmjs.org/kind-of/-/kind-of-3.2.2.tgz",
"integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=",
"optional": true,
"requires": { "requires": {
"is-buffer": "^1.1.5" "is-buffer": "^1.1.5"
} }
@ -883,6 +890,7 @@
"version": "2.1.1", "version": "2.1.1",
"resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-2.1.1.tgz", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-2.1.1.tgz",
"integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=", "integrity": "sha1-GrKLVW4Zg2Oowab35vogE3/mrtk=",
"optional": true,
"requires": { "requires": {
"remove-trailing-separator": "^1.0.1" "remove-trailing-separator": "^1.0.1"
} }
@ -1031,12 +1039,14 @@
"remove-trailing-separator": { "remove-trailing-separator": {
"version": "1.1.0", "version": "1.1.0",
"resolved": "https://registry.npmjs.org/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz", "resolved": "https://registry.npmjs.org/remove-trailing-separator/-/remove-trailing-separator-1.1.0.tgz",
"integrity": "sha1-wkvOKig62tW8P1jg1IJJuSN52O8=" "integrity": "sha1-wkvOKig62tW8P1jg1IJJuSN52O8=",
"optional": true
}, },
"repeat-element": { "repeat-element": {
"version": "1.1.2", "version": "1.1.2",
"resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.2.tgz", "resolved": "https://registry.npmjs.org/repeat-element/-/repeat-element-1.1.2.tgz",
"integrity": "sha1-7wiaF40Ug7quTZPrmLT55OEdmQo=" "integrity": "sha1-7wiaF40Ug7quTZPrmLT55OEdmQo=",
"optional": true
}, },
"repeat-string": { "repeat-string": {
"version": "1.6.1", "version": "1.6.1",
@ -1047,7 +1057,8 @@
"safe-buffer": { "safe-buffer": {
"version": "5.1.1", "version": "5.1.1",
"resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.1.tgz", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.1.tgz",
"integrity": "sha512-kKvNJn6Mm93gAczWVJg7wH+wGYWNrDHdWvpUmHyEsgCtIwwo3bqPtV4tR5tuPaUhTOo/kvhVwd8XwwOllGYkbg==" "integrity": "sha512-kKvNJn6Mm93gAczWVJg7wH+wGYWNrDHdWvpUmHyEsgCtIwwo3bqPtV4tR5tuPaUhTOo/kvhVwd8XwwOllGYkbg==",
"optional": true
}, },
"set-immediate-shim": { "set-immediate-shim": {
"version": "1.0.1", "version": "1.0.1",