title: AngularJS : How to use one resolve for all the routes of my application
body: <p>I would like to resolve the promise that loads the current user for all the pages of my application. 
  Currently I repeat the resolve in every <code>$routeProvider.when()</code> of my routes.</p>
  
  <pre><code>  $routeProvider.when('/users/edit/:userId', {
    templateUrl: 'app/app/assets/partials/user-edit.html', 
    controller: 'UserEditController',
    resolve:{  
      'currentUser':function( UserService){            
          return UserService.getCurrentUser();
        }
    }
    });  
  
    $routeProvider.when('/staff_profil/edit', {
    templateUrl: 'app/app/assets/partials/profil-edit.html', 
    controller: 'ProfilEditController',
    resolve:{  
      'currentUser':function( UserService){            
          return UserService.getCurrentUser();
        }
    }
   });
  </code></pre>
  
  <p>My goal is to resolve my current user for all the routes without repetition.</p>