Commit e1ec78e2 authored by Ramin Halavati's avatar Ramin Halavati Committed by Commit Bot

Update TestingProfile::GetProfileType() for guest mode.

TestingProfile::GetProfileType() returned GUEST_PROFILE for the regular
profile of a guest session. This behavior was different from that of
the ProfileImpl and OffTheRecordProfileImpl.

Bug: 947933
Change-Id: I0323587abecd9c4f07d5e320cacf651ef01c1c36
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1627365Reviewed-by: default avatarMihai Sardarescu <msarda@chromium.org>
Reviewed-by: default avatarMartin Šrámek <msramek@chromium.org>
Commit-Queue: Ramin Halavati <rhalavati@chromium.org>
Cr-Commit-Position: refs/heads/master@{#663034}
parent 760e5935
......@@ -84,7 +84,7 @@ scoped_refptr<RefcountedKeyedService>
scoped_refptr<HostContentSettingsMap> settings_map(new HostContentSettingsMap(
profile->GetPrefs(), profile->IsIncognitoProfile(),
profile->IsGuestProfile(),
profile->IsGuestSession(),
/*store_last_modified=*/true,
base::FeatureList::IsEnabled(features::kPermissionDelegation)));
......
......@@ -710,10 +710,8 @@ std::string TestingProfile::GetProfileUserName() const {
}
Profile::ProfileType TestingProfile::GetProfileType() const {
if (guest_session_)
return GUEST_PROFILE;
if (original_profile_)
return INCOGNITO_PROFILE;
return guest_session_ ? GUEST_PROFILE : INCOGNITO_PROFILE;
return REGULAR_PROFILE;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment