Skip to content

Commit d8f629e

Browse files
authored
Merge pull request #2721 from brandonpage/profile_photo
Fix profile photo download.
2 parents 13b5611 + 4d8f33f commit d8f629e

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

libs/SalesforceSDK/src/com/salesforce/androidsdk/accounts/UserAccount.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -725,7 +725,8 @@ public void downloadProfilePhoto() {
725725
// Checks if DownloadManager is enabled on the device, to ensure it doesn't crash.
726726
final PackageManager pm = SalesforceSDKManager.getInstance().getAppContext().getPackageManager();
727727
int state = pm.getApplicationEnabledSetting("com.android.providers.downloads");
728-
if (state == PackageManager.COMPONENT_ENABLED_STATE_ENABLED) {
728+
if (state == PackageManager.COMPONENT_ENABLED_STATE_ENABLED ||
729+
state == PackageManager.COMPONENT_ENABLED_STATE_DEFAULT) {
729730
final DownloadManager.Request downloadReq = new DownloadManager.Request(srcUri);
730731
downloadReq.setDestinationUri(destUri);
731732
downloadReq.addRequestHeader(AUTHORIZATION, BEARER + authToken);

0 commit comments

Comments
 (0)