Working through a test app with a service and I keep getting an error about adding the service using the factory method. Not sure why, i know i am probably staring right at the problem.. 

The error i get is:

VM497 angular.js:10126 Error: [$injector:unpr] Unknown provider: githubProvider <- github
<http://errors.angularjs.org/1.2.28/>$injector/unpr?p0=githubProvider%20%3C-%20github

Thanks in advance.

```
(function() {

  var github = function($http) {

    var getUser = function(username) {
      return $http.get('https://api.github.com/users/' + username).then(function(response) {
        return response.data
      });
    };

    var getRepos = function(user) {
      return $http.get(user.repos_url).then(function(response) {
        return response.data;
      });
    }; 

    return {
      getUser: getUser,
      getRepos: getRepos
    };
  }; 

  var module = angular.module("githubViewer");
  module.factory('github', github) ; 
});

```

Controller that injects the service

```
// Code goes here
(function() {
var app = angular.module("githubviewer", []); 

  var MainController = function(
$scope, github, $interval, 
$log, $anchorScroll, $location) {

var onUserComplete = function(data) {
  $scope.user = data;
  github.getRepos($scope.user).then(onRepos, onError);
};

var onRepos = function(data){
  $scope.repos = data;
  $location.hash("userDetails");
  $anchorScroll();
}

var onError = function(reason) {
  $scope.error = "Could not fetch the Data";
};

var decrementCountDown = function(){
  $scope.countdown -= 1;
  if($scope.countdown < 1){
    $scope.search($scope.username);
  } 
};

var countDownInterval = null;
var startCountDown = function(){
   countDownInterval = $interval(decrementCountDown, 1000, $scope.countdown);
};

   $scope.search = function(username){
 $log.info("Searching for: " + username);
 github.getUser(userName).then(onUserComplete, onError); 

  if (countDownInterval) {
    $interval.cancel(countDownInterval);
  }

    };

$scope.username = "angular";
$scope.message = "GitHub Viewer";
$scope.repoSortOrder = "-stargazers_count";
$scope.countdown = 5;
startCountDown();

};

app.controller("MainController", MainController)

}());  

```