From 8c53aa989a21e816e68107df940bc3caeeb6e548 Mon Sep 17 00:00:00 2001 From: danielghost Date: Fri, 24 May 2024 15:02:07 +0100 Subject: [PATCH] Update: implement missing `_logState` condition (fixes #194). --- js/models.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/models.js b/js/models.js index a3c068f..826dde5 100644 --- a/js/models.js +++ b/js/models.js @@ -324,7 +324,8 @@ export function addButtonComponents() { * Pretty print locking state for current page */ export function logTrickleState() { - if (logging._config?._level !== 'debug') return; + const trickleConfig = Adapt.config.get('_trickle'); + if (!trickleConfig?._logState || logging._config?._level !== 'debug') return; if (!Adapt.parentView?.model?.isTypeGroup('page')) { logging.debug('TRICKLE GLOBAL STATE'); Adapt.course.getAllDescendantModels(true).filter(model => model.get('_isAvailable')).forEach(model => {