Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ _This release is scheduled to be released on 2021-01-01._
- update Node-ical 0.12.4 , fix invalid RRULE format in cal entries
- fix package.json for optional electron dependency (2378)
- update node-ical version again, 0.12.5, change RRULE fix (#2371, #2379)
- Added missing function call in module.show()

## [2.13.0] - 2020-10-01

Expand Down
2 changes: 1 addition & 1 deletion js/check_config.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ function checkConfigFile() {
try {
fs.accessSync(configFileName, fs.F_OK);
} catch (e) {
Log.log(Utils.colors.error(e));
Log.error(Utils.colors.error(e));
throw new Error("No permission to access config file!");
}

Expand Down
22 changes: 13 additions & 9 deletions js/module.js
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ var Module = Class.extend({
* Set the module config and combine it with the module defaults.
*
* @param {object} config The combined module config.
* @param {boolean} config Merge module config in deep.
* @param {boolean} deep Merge module config in deep.
*/
setConfig: function (config, deep) {
this.config = deep ? configMerge({}, this.defaults, config) : Object.assign({}, this.defaults, config);
Expand Down Expand Up @@ -434,20 +434,22 @@ var Module = Class.extend({
speed,
function () {
self.resume();
callback;
callback();
},
options
);
}
});

/** Merging MagicMirror (or other) default/config script
* merge 2 objects or/with array
* using:
/**
* Merging MagicMirror (or other) default/config script by @bugsounet
* Merge 2 objects or/with array
*
* Usage:
* -------
* this.config = configMerge({}, this.defaults, this.config)
* -------
* arg1: initial objet
* arg1: initial object
* arg2: config model
* arg3: config to merge
* -------
Expand All @@ -456,10 +458,12 @@ var Module = Class.extend({
* it don't merge all thing in deep
* -> object in object and array is not merging
* -------
* @bugsounet
* @Todo: idea of Mich determinate what do you want to merge or not
*
* Todo: idea of Mich determinate what do you want to merge or not
*
* @param {object} result the initial object
* @returns {object} the merged config
*/

function configMerge(result) {
var stack = Array.prototype.slice.call(arguments, 1);
var item;
Expand Down
2 changes: 1 addition & 1 deletion js/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ var Server = function (config, callback) {
server.listen(port, config.address ? config.address : "localhost");

if (config.ipWhitelist instanceof Array && config.ipWhitelist.length === 0) {
Log.info(Utils.colors.warn("You're using a full whitelist configuration to allow for all IPs"));
Log.warn(Utils.colors.warn("You're using a full whitelist configuration to allow for all IPs"));
}

app.use(function (req, res, next) {
Expand Down