From e68e8c8e9c4d43123f5758c58e523ec0e6e060fa Mon Sep 17 00:00:00 2001 From: Johannes Meyer Date: Wed, 14 Oct 2020 09:13:18 +0200 Subject: [PATCH] loader.js: Only discard content if a renderHook returns null Previously any false value had this effect, though empty strings were also discarded due to this. However, in case an empty string is the content in the first place, the content must be updated. --- public/js/icinga/loader.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/js/icinga/loader.js b/public/js/icinga/loader.js index e146fc7c5..4b420a6b5 100644 --- a/public/js/icinga/loader.js +++ b/public/js/icinga/loader.js @@ -1127,7 +1127,7 @@ $.each(_this.icinga.behaviors, function(name, behavior) { if (behavior.renderHook) { var changed = behavior.renderHook(content, $container, action, autorefresh); - if (!changed) { + if (changed === null) { discard = true; } else { content = changed;