package vn.vinfast.paymentkit.repositories;

/* JADX INFO: compiled from: r8-map-id-ae6aab8d9a1033945587ffdd1bc6222159522c1d66e66a2c4cecb065134dd0a6 */
/* JADX INFO: loaded from: E:\ios\vf_dex\classes15.dex */
@kotlin.Metadata(d1 = {"\u0000\u000e\n\u0000\n\u0002\u0010\u0002\n\u0002\u0018\u0002\n\u0002\u0018\u0002\u0010\u0000\u001a\u00020\u0001*\b\u0012\u0004\u0012\u00020\u00030\u0002H\n"}, d2 = {"<anonymous>", "", "Lkotlinx/coroutines/flow/FlowCollector;", "Lvn/vinfast/paymentkitapi/models/autopayment/AutoPaymentModel;"}, k = 3, mv = {2, 2, 0}, xi = 48)
@kotlin.coroutines.jvm.internal.DebugMetadata(c = "vn.vinfast.paymentkit.repositories.AutoPaymentRepoImpl$getVehicleAutoPayDetail$1", f = "AutoPaymentRepoImpl.kt", l = {26, 27}, m = "invokeSuspend", v = 1)
final class AutoPaymentRepoImpl$getVehicleAutoPayDetail$1 extends kotlin.coroutines.jvm.internal.SuspendLambda implements kotlin.jvm.functions.Function2<kotlinx.coroutines.flow.FlowCollector<? super vn.vinfast.paymentkitapi.models.autopayment.AutoPaymentModel>, kotlin.coroutines.Continuation<? super kotlin.Unit>, java.lang.Object> {
    java.lang.Object n;
    int o;
    private /* synthetic */ java.lang.Object p;
    final /* synthetic */ vn.vinfast.paymentkit.repositories.AutoPaymentRepoImpl q;
    final /* synthetic */ java.lang.String r;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    AutoPaymentRepoImpl$getVehicleAutoPayDetail$1(vn.vinfast.paymentkit.repositories.AutoPaymentRepoImpl autoPaymentRepoImpl, java.lang.String str, kotlin.coroutines.Continuation continuation) {
        super(2, continuation);
        this.q = autoPaymentRepoImpl;
        this.r = str;
    }

    /* JADX INFO: renamed from: a, reason: merged with bridge method [inline-methods] */
    public final java.lang.Object invoke(kotlinx.coroutines.flow.FlowCollector flowCollector, kotlin.coroutines.Continuation continuation) {
        return create(flowCollector, continuation).invokeSuspend(kotlin.Unit.a);
    }

    public final kotlin.coroutines.Continuation create(java.lang.Object obj, kotlin.coroutines.Continuation continuation) {
        vn.vinfast.paymentkit.repositories.AutoPaymentRepoImpl$getVehicleAutoPayDetail$1 autoPaymentRepoImpl$getVehicleAutoPayDetail$1 = new vn.vinfast.paymentkit.repositories.AutoPaymentRepoImpl$getVehicleAutoPayDetail$1(this.q, this.r, continuation);
        autoPaymentRepoImpl$getVehicleAutoPayDetail$1.p = obj;
        return autoPaymentRepoImpl$getVehicleAutoPayDetail$1;
    }

    /* JADX WARN: Code restructure failed: missing block: B:14:0x005f, code lost:
    
        if (r0.emit(r2, r5) == r1) goto L15;
     */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
        To view partially-correct add '--show-bad-code' argument
    */
    public final java.lang.Object invokeSuspend(java.lang.Object r6) {
        /*
            r5 = this;
            java.lang.Object r0 = r5.p
            kotlinx.coroutines.flow.FlowCollector r0 = (kotlinx.coroutines.flow.FlowCollector) r0
            java.lang.Object r1 = kotlin.coroutines.intrinsics.IntrinsicsKt.g()
            int r2 = r5.o
            r3 = 2
            r4 = 1
            if (r2 == 0) goto L26
            if (r2 == r4) goto L22
            if (r2 != r3) goto L1a
            java.lang.Object r5 = r5.n
            vn.vinfast.paymentkit.datasources.remote.responses.AutoPaymentModelDto r5 = (vn.vinfast.paymentkit.datasources.remote.responses.AutoPaymentModelDto) r5
            kotlin.ResultKt.b(r6)
            goto L62
        L1a:
            java.lang.IllegalStateException r5 = new java.lang.IllegalStateException
            java.lang.String r6 = "call to 'resume' before 'invoke' with coroutine"
            r5.<init>(r6)
            throw r5
        L22:
            kotlin.ResultKt.b(r6)
            goto L3c
        L26:
            kotlin.ResultKt.b(r6)
            vn.vinfast.paymentkit.repositories.AutoPaymentRepoImpl r6 = r5.q
            vn.vinfast.paymentkit.datasources.remote.PaymentApi r6 = vn.vinfast.paymentkit.repositories.AutoPaymentRepoImpl.d(r6)
            java.lang.String r2 = r5.r
            r5.p = r0
            r5.o = r4
            java.lang.Object r6 = r6.h(r2, r5)
            if (r6 != r1) goto L3c
            goto L61
        L3c:
            com.vinfast.companion.corenetwork.BaseResponse r6 = (com.vinfast.companion.corenetwork.BaseResponse) r6
            java.lang.Object r6 = r6.a()
            vn.vinfast.paymentkit.datasources.remote.responses.AutoPaymentModelDto r6 = (vn.vinfast.paymentkit.datasources.remote.responses.AutoPaymentModelDto) r6
            vn.vinfast.paymentkit.datasources.remote.responses.AutoPaymentModelDto$Companion r2 = vn.vinfast.paymentkit.datasources.remote.responses.AutoPaymentModelDto.INSTANCE
            vn.vinfast.paymentkitapi.models.autopayment.AutoPaymentModel r2 = r2.a(r6)
            kotlin.jvm.internal.Intrinsics.i(r2)
            java.lang.Object r4 = kotlin.coroutines.jvm.internal.SpillingKt.a(r0)
            r5.p = r4
            java.lang.Object r6 = kotlin.coroutines.jvm.internal.SpillingKt.a(r6)
            r5.n = r6
            r5.o = r3
            java.lang.Object r5 = r0.emit(r2, r5)
            if (r5 != r1) goto L62
        L61:
            return r1
        L62:
            kotlin.Unit r5 = kotlin.Unit.a
            return r5
        */
        throw new UnsupportedOperationException("Method not decompiled: vn.vinfast.paymentkit.repositories.AutoPaymentRepoImpl$getVehicleAutoPayDetail$1.invokeSuspend(java.lang.Object):java.lang.Object");
    }
}
