Phuedx has uploaded a new change for review. ( https://gerrit.wikimedia.org/r/350552 )
Change subject: Remove isLoggingEnabled with Null Object pattern ...................................................................... Remove isLoggingEnabled with Null Object pattern The statsv change listener depended on both the analytics tracking function and whether it should log metrics to StatsD. We can simplify the behaviour of the change listener by passing in a function which doesn't log metrics to StatsD if such logging is disabled. The change listener is now more isolated from other components. Moreover, sharing the analytics tracking function with other components is simpler as there's no repeated code. Bug: T163198 Change-Id: Ibf4785fa4c27c1ad4739f02410f57412f56ff481 --- M resources/dist/index.js M resources/dist/index.js.map M src/changeListeners/statsv.js M src/index.js M tests/node-qunit/changeListeners/statsv.test.js 5 files changed, 79 insertions(+), 58 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/Popups refs/changes/52/350552/1 -- To view, visit https://gerrit.wikimedia.org/r/350552 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ibf4785fa4c27c1ad4739f02410f57412f56ff481 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/Popups Gerrit-Branch: master Gerrit-Owner: Phuedx <[email protected]> _______________________________________________ MediaWiki-commits mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
