title: $rootScope is undefined in controller
body: <p>I am getting very strange issue in angular. I have defined $rootScope.user_info in run method. But when i am fetching the root scope in controller, sometimes i am getting undefined method $rootScope.user_info in controller. any idea why this is happen sometimes when i refresh a page?</p>
  
  <p>Here is the code snippets,</p>
  
  <pre><code>myApp.run(['$http', '$rootScope','$location','localStorageService','$window','$translate','$timeout', function($http, $rootScope,$location,localStorageService,$window,$translate,$timeout) {
      $rootScope.current_user_id = localStorageService.get("CurrentUserId");
      $rootScope.get_user_profile = function() {
          $http.get('/api/v1/employees/'+$rootScope.current_user_id).success(function(response) {
              $rootScope.user_info = response["data"]["user_info"];
          });
      };
  
      if ($rootScope.current_user_id) {
          $rootScope.get_user_profile();
      }
  }]);
  
  myApp.controller('ProfileCtr', ['$rootScope','$scope','Employee','fileReader','$translate','$filter','checkResponse','toaster', function($rootScope,$scope, Employee,fileReader,$translate,$filter,checkResponse,toaster){
      $scope.langs = [ { name: "en",value: "English"}, { name: "de_DE", value: "German"}, { name: "fr_FR", value: "French"} ];
      $scope.set_language = function() {
          $scope.selectLang = $filter('filter')($scope.langs, { name: $rootScope.user_info.eselected_language})[0];
      }
      $scope.set_language();
  });
  </code></pre>