title: Angular Uncaught Object
body: <p>I'm new to Angular so i'm still getting my head around how it works. I've stumbled into a problem however (quite early on...) and the below code is giving me "Uncaught Object" in the console and breaks Angular. The .config section is the culprit, if I remove it, the page loads fine. I'm not entirely sure how the error is being caused because to me, everything looks fine?</p>
  
  <pre><code>var app = angular.module('app', ['ngRoute'])
  
      .config(['$routeProvider', '$locationProvider', function ($routeProvider, $locationProvider) {
          $routeProvider
              .when('/dashboard', {
                  templateUrl: '/app/views/admin.html',
                  controller: 'DashboardController'
              })
              .otherwise('/', {
                  redirectTo: '/'
              })
  
          $locationProvider.html5mode(true);
      }])
  
      .controller('DashboardController', ['$scope', function ($scope, Security) {
          $scope.security = Security;
      }])
  </code></pre>