Merge "Add a missing null check to BeginGetCredentialOption" into udc-dev am: 827e21eb44

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/21524369

Change-Id: Id056a4ea03135b227fa2ec5ed2dacdb10b14be33
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
James Willcox
2023-02-24 18:33:39 +00:00
committed by Automerger Merge Worker

View File

@@ -116,12 +116,12 @@ public class BeginGetCredentialOption implements Parcelable {
* @param id the unique id associated with this option * @param id the unique id associated with this option
* @param type the requested credential type * @param type the requested credential type
* @param candidateQueryData the request candidateQueryData * @param candidateQueryData the request candidateQueryData
* @throws IllegalArgumentException If type is empty. * @throws IllegalArgumentException If id or type is empty.
*/ */
public BeginGetCredentialOption( public BeginGetCredentialOption(
@NonNull String id, @NonNull String type, @NonNull String id, @NonNull String type,
@NonNull Bundle candidateQueryData) { @NonNull Bundle candidateQueryData) {
mId = id; mId = Preconditions.checkStringNotEmpty(id, "id must not be empty");
mType = Preconditions.checkStringNotEmpty(type, "type must not be empty"); mType = Preconditions.checkStringNotEmpty(type, "type must not be empty");
Bundle bundle = new Bundle(); Bundle bundle = new Bundle();
bundle.putAll(candidateQueryData); bundle.putAll(candidateQueryData);