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

Commit 201a936f authored by Anna Bauza's avatar Anna Bauza Committed by Android (Google) Code Review
Browse files

Merge "Fix system server crash when AvatarPickerActivity started without file authority" into main

parents 9a5578f9 6ad6b169
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -25,6 +25,7 @@ import android.graphics.drawable.BitmapDrawable;
import android.graphics.drawable.Drawable;
import android.net.Uri;
import android.os.Bundle;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
@@ -138,7 +139,8 @@ public class AvatarPickerActivity extends Activity {
    private String getFileAuthority() {
        String authority = getIntent().getStringExtra(EXTRA_FILE_AUTHORITY);
        if (authority == null) {
            throw new IllegalStateException("File authority must be provided");
            Log.e(this.getClass().getName(), "File authority must be provided");
            finish();
        }
        return authority;
    }