app.controller('boltCtrl', [ '$scope', 'Auth', function($scope, Auth) { var vm = this; vm.userName = function(profile){ profile = Auth.getProfile(); return profile.email; }; }]);