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

Commit 8a203951 authored by Svetoslav Ganov's avatar Svetoslav Ganov Committed by android-build-merger
Browse files

Merge "Improve requestPermissions API docs and throw correct exception." into nyc-dev

am: 0f3431b6

* commit '0f3431b6':
  Improve requestPermissions API docs and throw correct exception.
parents aa820e1b 0f3431b6
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -4100,7 +4100,7 @@ public class Activity extends ContextThemeWrapper
     * }
     * </code></pre></p>
     *
     * @param permissions The requested permissions.
     * @param permissions The requested permissions. Must me non-null and not empty.
     * @param requestCode Application specific request code to match with a result
     *    reported to {@link #onRequestPermissionsResult(int, String[], int[])}.
     *    Should be >= 0.
+1 −1
Original line number Diff line number Diff line
@@ -1203,7 +1203,7 @@ public class Fragment implements ComponentCallbacks2, OnCreateContextMenuListene
     * }
     * </code></pre></p>
     *
     * @param permissions The requested permissions.
     * @param permissions The requested permissions. Must me non-null and not empty.
     * @param requestCode Application specific request code to match with a result
     *    reported to {@link #onRequestPermissionsResult(int, String[], int[])}.
     *    Should be >= 0.
+1 −1
Original line number Diff line number Diff line
@@ -3175,7 +3175,7 @@ public abstract class PackageManager {
     */
    public Intent buildRequestPermissionsIntent(@NonNull String[] permissions) {
        if (ArrayUtils.isEmpty(permissions)) {
           throw new NullPointerException("permission cannot be null or empty");
           throw new IllegalArgumentException("permission cannot be null or empty");
        }
        Intent intent = new Intent(ACTION_REQUEST_PERMISSIONS);
        intent.putExtra(EXTRA_REQUEST_PERMISSIONS_NAMES, permissions);