Skip to content
This repository has been archived by the owner on Feb 28, 2022. It is now read-only.

Commit

Permalink
fix: add strict-di support by adding $inject
Browse files Browse the repository at this point in the history
  • Loading branch information
toutpt committed May 24, 2016
1 parent f2bebe8 commit 1399df3
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
8 changes: 5 additions & 3 deletions src/leaflet.controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,12 @@ function leafletCtrl($element, leafletService) {
if (!L.Icon.Default.imagePath && leafletService.settings.imagePath) {
L.Icon.Default.imagePath = leafletService.settings.imagePath;
}
leafletService.data[$ctrl.mapid] = L.map($ctrl.mapid);
leafletService.updateMapFromSettings(leafletService.data[$ctrl.mapid]);
$ctrl.onMapInitialized({map: leafletService.data[$ctrl.mapid]});
var map = L.map($ctrl.mapid);
leafletService.data[$ctrl.mapid] = map;
leafletService.updateMapFromSettings(map);
$ctrl.onMapInitialized({map: map});
};
}

leafletCtrl.$inject = ['$element', 'leafletService'];
export default leafletCtrl;
1 change: 1 addition & 0 deletions src/leaflet.provider.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ function provider() {
}
return service;
};
this.$get.$inject = ['$compile'];
}

export default provider;
2 changes: 1 addition & 1 deletion src/leaflet.service.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,5 +41,5 @@ function LeafletService($compile) {
};

}

LeafletService.$inject = ['$compile'];
export default LeafletService;

0 comments on commit 1399df3

Please sign in to comment.