Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit dd9157ce authored by Amith Yamasani's avatar Amith Yamasani Committed by Android Git Automerger
Browse files

am b926d484: Merge "Handle the case where the restore environment doesn\'t...

am b926d484: Merge "Handle the case where the restore environment doesn\'t have the ringtone" into klp-dev

* commit 'b926d484':
  Handle the case where the restore environment doesn't have the ringtone
parents 33f92b6f b926d484
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -104,6 +104,10 @@ public class SettingsHelper {
        } else {
            Uri canonicalUri = Uri.parse(value);
            ringtoneUri = mContext.getContentResolver().uncanonicalize(canonicalUri);
            if (ringtoneUri == null) {
                // Unrecognized or invalid Uri, don't restore
                return;
            }
        }
        final int ringtoneType = Settings.System.RINGTONE.equals(name)
                ? RingtoneManager.TYPE_RINGTONE : RingtoneManager.TYPE_NOTIFICATION;