From 88c80973f18e500129c88b2abe764704101ca835 Mon Sep 17 00:00:00 2001 From: rejas Date: Fri, 5 Feb 2021 22:40:05 +0100 Subject: [PATCH 1/2] Dont updateDOM when the module is not displayed --- js/main.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/js/main.js b/js/main.js index b7138d99..6bdbbc3e 100644 --- a/js/main.js +++ b/js/main.js @@ -547,6 +547,11 @@ var MM = (function () { return; } + if (!module.data.position) { + Log.warn("module tries to update the DOM without being displayed."); + return; + } + // Further implementation is done in the private method. updateDom(module, speed); }, From 16615c3da20f50ba6f57668e4f54366593acd2ff Mon Sep 17 00:00:00 2001 From: rejas Date: Fri, 5 Feb 2021 22:40:44 +0100 Subject: [PATCH 2/2] Update CHANGELOG --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 54ade1fd..6557937a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,7 @@ _This release is scheduled to be released on 2021-04-01._ - Converted newsfeed module to use templates. - Update documentation and help screen about invalid config files. - Moving weather provider specific code and configuration into each provider and making hourly part of the interface. +- Dont update the DOM when a module is not displayed. ### Removed