package com.vinfast.companion.notification.ui.campaign;

/* JADX INFO: compiled from: r8-map-id-ae6aab8d9a1033945587ffdd1bc6222159522c1d66e66a2c4cecb065134dd0a6 */
/* JADX INFO: loaded from: E:\ios\vf_dex\classes4.dex */
@kotlin.Metadata(d1 = {"\u0000\n\n\u0000\n\u0002\u0010\u0002\n\u0002\u0018\u0002\u0010\u0000\u001a\u00020\u0001*\u00020\u0002H\n"}, d2 = {"<anonymous>", "", "Lkotlinx/coroutines/CoroutineScope;"}, k = 3, mv = {2, 2, 0}, xi = 48)
@kotlin.coroutines.jvm.internal.DebugMetadata(c = "com.vinfast.companion.notification.ui.campaign.NotificationVehicleCampaignFragment$onFragmentCreated$1$2$1", f = "NotificationVehicleCampaignFragment.kt", l = {85}, m = "invokeSuspend", v = 1)
final class NotificationVehicleCampaignFragment$onFragmentCreated$1$2$1 extends kotlin.coroutines.jvm.internal.SuspendLambda implements kotlin.jvm.functions.Function2<kotlinx.coroutines.CoroutineScope, kotlin.coroutines.Continuation<? super kotlin.Unit>, java.lang.Object> {
    java.lang.Object n;
    int o;
    final /* synthetic */ com.vinfast.companion.notification.ui.campaign.NotificationVehicleCampaignFragment p;
    final /* synthetic */ java.lang.String q;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    NotificationVehicleCampaignFragment$onFragmentCreated$1$2$1(com.vinfast.companion.notification.ui.campaign.NotificationVehicleCampaignFragment notificationVehicleCampaignFragment, java.lang.String str, kotlin.coroutines.Continuation continuation) {
        super(2, continuation);
        this.p = notificationVehicleCampaignFragment;
        this.q = str;
    }

    public final kotlin.coroutines.Continuation create(java.lang.Object obj, kotlin.coroutines.Continuation continuation) {
        return new com.vinfast.companion.notification.ui.campaign.NotificationVehicleCampaignFragment$onFragmentCreated$1$2$1(this.p, this.q, continuation);
    }

    public final java.lang.Object invokeSuspend(java.lang.Object obj) {
        com.vinfast.companion.notification.ui.campaign.NotificationVehicleCampaignFragment notificationVehicleCampaignFragment;
        java.lang.Object objG = kotlin.coroutines.intrinsics.IntrinsicsKt.g();
        int i = this.o;
        try {
            if (i == 0) {
                kotlin.ResultKt.b(obj);
                this.p.Q1(com.vinfast.companion.core.base.ProgressType.ProgressDialog.b);
                com.vinfast.companion.notification.ui.campaign.NotificationVehicleCampaignFragment notificationVehicleCampaignFragment2 = this.p;
                kotlinx.coroutines.flow.Flow flowN = notificationVehicleCampaignFragment2.Y1().N(this.q);
                this.n = notificationVehicleCampaignFragment2;
                this.o = 1;
                java.lang.Object objH = kotlinx.coroutines.flow.FlowKt.H(flowN, this);
                if (objH == objG) {
                    return objG;
                }
                notificationVehicleCampaignFragment = notificationVehicleCampaignFragment2;
                obj = objH;
            } else {
                if (i != 1) {
                    throw new java.lang.IllegalStateException("call to 'resume' before 'invoke' with coroutine");
                }
                notificationVehicleCampaignFragment = (com.vinfast.companion.notification.ui.campaign.NotificationVehicleCampaignFragment) this.n;
                kotlin.ResultKt.b(obj);
            }
            notificationVehicleCampaignFragment.recallCampaignData = (com.vinfast.companion.serviceskit.domain.model.RecallCampaign) obj;
            this.p.X0(com.vinfast.companion.core.base.ViewModelState.Idle.a);
            this.p.Z1();
        } catch (java.lang.Exception e) {
            timber.log.Timber.a.e(e, "Failed to fetch recall campaign detail on click", new java.lang.Object[0]);
            this.p.X0(com.vinfast.companion.core.base.ViewModelState.Idle.a);
            this.p.Z1();
        }
        return kotlin.Unit.a;
    }

    public final java.lang.Object invoke(kotlinx.coroutines.CoroutineScope coroutineScope, kotlin.coroutines.Continuation continuation) {
        return create(coroutineScope, continuation).invokeSuspend(kotlin.Unit.a);
    }
}
