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

Commit 9710b9f8 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "catch fatal exception when fetching rintone that doesnt exist"

parents 80605ba8 c2feecb2
Loading
Loading
Loading
Loading
+10 −10
Original line number Diff line number Diff line
@@ -80,8 +80,8 @@ public class RingtoneFactory {
            try {
                ringtone = RingtoneManager.getRingtone(
                        userContext, ringtoneUri, volumeShaperConfig, audioAttrs);
            } catch (NullPointerException npe) {
                Log.e(this, npe, "getRingtone: NPE while getting ringtone.");
            } catch (Exception e) {
                Log.e(this, e, "getRingtone: exception while getting ringtone.");
            }
        }
        if (ringtone == null) {
@@ -109,8 +109,8 @@ public class RingtoneFactory {
            try {
                ringtone = RingtoneManager.getRingtone(
                        contextToUse, defaultRingtoneUri, volumeShaperConfig, audioAttrs);
            } catch (NullPointerException npe) {
                Log.e(this, npe, "getRingtone: NPE while getting ringtone.");
            } catch (Exception e) {
                Log.e(this, e, "getRingtone: exception while getting ringtone.");
            }
        }
        return ringtone;