diff options
Diffstat (limited to 'js/controller')
-rw-r--r-- | js/controller/AppController.js | 6 | ||||
-rw-r--r-- | js/controller/ContentController.js | 7 |
2 files changed, 8 insertions, 5 deletions
diff --git a/js/controller/AppController.js b/js/controller/AppController.js index b833d3fe1..17471e71e 100644 --- a/js/controller/AppController.js +++ b/js/controller/AppController.js @@ -7,12 +7,14 @@ * @author Bernhard Posselt <dev@bernhard-posselt.com> * @copyright Bernhard Posselt 2014 */ -app.controller('AppController', function (Loading, FeedResource, FolderResource) { +app.controller('AppController', +function (Loading, FeedResource, FolderResource) { + 'use strict'; this.loading = Loading; - this.isFirstRun = function () { + this.isFirstRun = () => { return FeedResource.size() === 0 && FolderResource.size() === 0; }; diff --git a/js/controller/ContentController.js b/js/controller/ContentController.js index 8e4632f7e..ae5116dbb 100644 --- a/js/controller/ContentController.js +++ b/js/controller/ContentController.js @@ -7,17 +7,18 @@ * @author Bernhard Posselt <dev@bernhard-posselt.com> * @copyright Bernhard Posselt 2014 */ -app.controller('ContentController', function (Publisher, FeedResource, ItemResource, data) { +app.controller('ContentController', +function (Publisher, FeedResource, ItemResource, data) { 'use strict'; // distribute data to models based on key Publisher.publishAll(data); - this.getItems = function () { + this.getItems = () => { return ItemResource.getAll(); }; - this.getFeeds = function () { + this.getFeeds = () => { return FeedResource.getAll(); }; });
\ No newline at end of file |