1
0
mirror of https://github.com/bitwarden/browser.git synced 2024-12-27 17:18:04 +01:00

allow null name

This commit is contained in:
Kyle Spearrin 2018-07-12 14:19:39 -04:00
parent f6a5979334
commit 67b2b53185
2 changed files with 1 additions and 2 deletions

View File

@ -8,7 +8,6 @@ import { AuthResult } from '../../models/domain/authResult';
import { AuthService } from '../../abstractions/auth.service'; import { AuthService } from '../../abstractions/auth.service';
import { I18nService } from '../../abstractions/i18n.service'; import { I18nService } from '../../abstractions/i18n.service';
import { SyncService } from '../../abstractions/sync.service';
export class LoginComponent { export class LoginComponent {
@Input() email: string = ''; @Input() email: string = '';

View File

@ -160,7 +160,7 @@ export class TokenService implements TokenServiceAbstraction {
getName(): string { getName(): string {
const decoded = this.decodeToken(); const decoded = this.decodeToken();
if (typeof decoded.name === 'undefined') { if (typeof decoded.name === 'undefined') {
throw new Error('No name found'); return null;
} }
return decoded.name as string; return decoded.name as string;