summaryrefslogtreecommitdiff
path: root/client/js
diff options
context:
space:
mode:
authormanzerbredes <loic.guegan_secondary@yahoo.fr>2016-03-02 07:25:28 +0100
committermanzerbredes <loic.guegan_secondary@yahoo.fr>2016-03-02 07:25:28 +0100
commitb6d7d2c30efe5e9758072bb82ea3a947bda7fd1d (patch)
tree211f6b88854dcb2dc761a295e3d6cc675008bd75 /client/js
parent2d99f1ecf2164431b03eff5bcbaa7abe67287602 (diff)
Correct bug
Diffstat (limited to 'client/js')
-rw-r--r--client/js/controllers/home/main.js10
1 files changed, 7 insertions, 3 deletions
diff --git a/client/js/controllers/home/main.js b/client/js/controllers/home/main.js
index 2e9c00b..f84f625 100644
--- a/client/js/controllers/home/main.js
+++ b/client/js/controllers/home/main.js
@@ -3,7 +3,7 @@
*
* @param {$scope} $scope The $scope service from angular
*/
-mainApp.controller('homeCtrl', [ '$scope', 'Compute', '$rootScope', 'Loading', function ($scope, Compute, $rootScope, Loading)
+mainApp.controller('homeCtrl', [ '$scope', 'Compute', '$rootScope', 'Loading','Identity', function ($scope, Compute, $rootScope, Loading, Identity)
{
var callMeAfterPullData=function(data){
@@ -11,8 +11,12 @@ mainApp.controller('homeCtrl', [ '$scope', 'Compute', '$rootScope', 'Loading', f
Loading.stop();
}
- Loading.start();
- Compute.pullData(callMeAfterPullData);
+ ;
+ if(Compute.getData().machines == null && Identity.isAlreadyLogin()){
+ Loading.start();
+ Compute.pullData(callMeAfterPullData);
+ }
+