fix typo with `rememberedEmailCookieName`

This commit is contained in:
Kyle Spearrin 2016-10-06 21:57:01 -04:00
parent 35d7f2e5f3
commit 711f1a07e9
3 changed files with 5 additions and 5 deletions

View File

@ -1,5 +1,5 @@
{ {
"appSettings": { "appSettings": {
"rememberdEmailCookieName": "bit.rememberedEmail" "rememberedEmailCookieName": "bit.rememberedEmail"
} }
} }

View File

@ -2,7 +2,7 @@ angular
.module('bit.accounts') .module('bit.accounts')
.controller('accountsLoginController', function ($scope, $rootScope, $cookies, apiService, cryptoService, authService, $state, appSettings, $analytics) { .controller('accountsLoginController', function ($scope, $rootScope, $cookies, apiService, cryptoService, authService, $state, appSettings, $analytics) {
var rememberedEmail = $cookies.get(appSettings.rememberdEmailCookieName); var rememberedEmail = $cookies.get(appSettings.rememberedEmailCookieName);
if (rememberedEmail) { if (rememberedEmail) {
$scope.model = { $scope.model = {
email: rememberedEmail, email: rememberedEmail,
@ -19,12 +19,12 @@ angular
cookieExpiration.setFullYear(cookieExpiration.getFullYear() + 10); cookieExpiration.setFullYear(cookieExpiration.getFullYear() + 10);
$cookies.put( $cookies.put(
appSettings.rememberdEmailCookieName, appSettings.rememberedEmailCookieName,
model.email, model.email,
{ expires: cookieExpiration }); { expires: cookieExpiration });
} }
else { else {
$cookies.remove(appSettings.rememberdEmailCookieName); $cookies.remove(appSettings.rememberedEmailCookieName);
} }
var profile = authService.getUserProfile(); var profile = authService.getUserProfile();

View File

@ -1,2 +1,2 @@
angular.module("bit") angular.module("bit")
.constant("appSettings", {"rememberdEmailCookieName":"bit.rememberedEmail","version":"0.0.1","environment":"Development","apiUri":"http://localhost:4000"}); .constant("appSettings", {"rememberedEmailCookieName":"bit.rememberedEmail","version":"0.0.1","environment":"Development","apiUri":"http://localhost:4000"});