From 9c2bb027d3e814d4c9d243eba984acd4b18eb493 Mon Sep 17 00:00:00 2001 From: psychobunny Date: Mon, 26 May 2014 12:26:41 -0400 Subject: [PATCH] fire action:widgets.loaded regardless of callback --- public/src/widgets.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/public/src/widgets.js b/public/src/widgets.js index 3fef6b2364..2ef647bfc4 100644 --- a/public/src/widgets.js +++ b/public/src/widgets.js @@ -66,9 +66,11 @@ function checkCallback() { numLocations--; - if (numLocations < 0 && callback) { - callback(); + if (numLocations < 0) { $(window).trigger('action:widgets.loaded', {}); + if (typeof callback === 'function') { + callback(); + } } }