From 42310f942754433ea4fc3405b79be2ed9705bd65 Mon Sep 17 00:00:00 2001 From: danielstorey Date: Tue, 23 Oct 2018 13:18:01 +0100 Subject: [PATCH] Fix issue #6 (#7) * Fix issue #6 Listen to adapt:start instead of app:dataReady. This ensures the extension is initialised each time the language is changed. * Bump version Also update semver --- bower.json | 4 ++-- js/adapt-aboutUs.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bower.json b/bower.json index a5fc679..7ef1697 100644 --- a/bower.json +++ b/bower.json @@ -1,7 +1,7 @@ { "name": "adapt-aboutUs", - "version": "1.2.1", - "framework": "^2.0.0", + "version": "1.2.2", + "framework": ">=2.0.0", "homepage": "https://github.com/chucklorenz/adapt-aboutUs", "issues": "https://github.com/chucklorenz/adapt-aboutUs/issues", "authors": [ diff --git a/js/adapt-aboutUs.js b/js/adapt-aboutUs.js index e53083a..34d41a5 100644 --- a/js/adapt-aboutUs.js +++ b/js/adapt-aboutUs.js @@ -26,10 +26,10 @@ define(function(require) { } - Adapt.once('app:dataReady', function() { + Adapt.on('adapt:start', function() { var courseAboutUs = Adapt.course.get('_aboutUs'); - if(courseAboutUs) { + if (courseAboutUs) { var drawerObject = { title: courseAboutUs.title, description: courseAboutUs.description,