what-the-bank/sources/com/google/android/libraries/places/internal/zzch.java

29 lines
1.2 KiB
Java
Raw Normal View History

2024-07-27 18:17:47 +07:00
package com.google.android.libraries.places.internal;
import com.google.android.gms.common.api.ApiException;
import com.google.android.gms.common.api.Status;
import com.google.android.gms.tasks.Continuation;
import com.google.android.gms.tasks.Task;
import com.google.android.gms.tasks.TaskCompletionSource;
/* loaded from: classes2.dex */
final class zzch implements Continuation {
final zzci zza;
@Override // com.google.android.gms.tasks.Continuation
public final /* synthetic */ Object then(Task task) throws Exception {
TaskCompletionSource taskCompletionSource = new TaskCompletionSource();
if (task.isCanceled()) {
taskCompletionSource.trySetException(new ApiException(new Status(16, "Location request was cancelled. Please try again.")));
} else if (task.getException() == null && task.getResult() == null) {
taskCompletionSource.trySetException(new ApiException(new Status(8, "Location unavailable.")));
}
return taskCompletionSource.getTask().getException() != null ? taskCompletionSource.getTask() : task;
}
/* JADX INFO: Access modifiers changed from: package-private */
public zzch(zzci zzciVar) {
this.zza = zzciVar;
}
}