17 lines
402 B
JavaScript
17 lines
402 B
JavaScript
app.controller('HomeController', ['$scope', 'Auth', 'localStorageService', '$location', '$rootScope', function ($scope, Auth, localStorageService, $location, $rootScope) {
|
|
var vm = this;
|
|
|
|
vm.signOut = function () {
|
|
localStorageService.remove('userAuth');
|
|
$location.path('/splash-page');
|
|
};
|
|
|
|
function userAuth() {
|
|
return JSON.parse(localStorageService.get('userAuth'));
|
|
}
|
|
|
|
|
|
|
|
|
|
}]);
|