Bug 1180106 - don't attempt to fetch an FxA user profile when no user is logged in. r=oeger

This commit is contained in:
Mark Hammond 2015-07-03 15:04:22 +10:00
parent fcca063783
commit 2564420a2a

View File

@ -313,7 +313,7 @@ let gFxAccounts = {
fxAccounts.getSignedInUser().then(userData => {
// userData may be null here when the user is not signed-in, but that's expected
updateWithUserData(userData);
return fxAccounts.getSignedInUserProfile();
return userData ? fxAccounts.getSignedInUserProfile() : null;
}).then(profile => {
if (!profile) {
return;