I would like to return the `.state('name')` when I change location in angular.

From my `run()` it can return the `$state` object:

```
 .run(function($rootScope, Analytics, $location, $stateParams, $state) {
      console.log($state);

```

![working object](https://i.stack.imgur.com/4lPWV.png)

**but when I try to get`$state.current` it is empty object**

```
.run(function($rootScope, $location, $stateParams, $state) {

      console.log($state.current);

```

![empty](https://i.stack.imgur.com/AlZlJ.png)

**config example:**

```
 .config(function($stateProvider, $urlRouterProvider, AnalyticsProvider) {  
        $urlRouterProvider.otherwise('/');
        $stateProvider
        .state('home', {
            url: '/',
            views: {
              '': {
                templateUrl: 'views/main.html',
                controller: 'MainCtrl'
              },
              'navigation@home': {
                templateUrl: 'views/partials/navigation.html',
                controller: 'NavigationCtrl'
              },
              'weekly@home': {
                templateUrl: 'views/partials/weekly.html',
                controller: 'WeeklyCtrl'
              },
              'sidepanel@home': {
                templateUrl: 'views/partials/side-panel.html',
                controller: 'SidePanelCtrl'
              },
              'shoppanel@home': {
                templateUrl: 'views/partials/shop-panel.html',
                controller: 'ShopPanelCtrl'
              },
              'footer@home': {
                templateUrl: 'views/partials/footer.html',
                controller: 'FooterCtrl'
              }
            }
          })

```