package com.sistemasolton.itranvias.home.presentation.stopdetail;

import androidx.compose.runtime.MutableState;
import androidx.compose.runtime.SnapshotStateKt__SnapshotStateKt;
import androidx.lifecycle.ViewModel;
import androidx.lifecycle.ViewModelKt;
import com.sistemasolton.itranvias.home.data.local.entity.StopFavoriteEntity;
import com.sistemasolton.itranvias.home.data.remote.dto.detalleparadadto.BusesDto;
import com.sistemasolton.itranvias.home.data.remote.dto.detalleparadadto.DetalleParadaDto;
import com.sistemasolton.itranvias.home.data.remote.dto.infodto.InfoDto;
import com.sistemasolton.itranvias.home.domain.usecase.GetInfoLocalUseCase;
import com.sistemasolton.itranvias.home.domain.usecase.GetStopDetailUseCase;
import com.sistemasolton.itranvias.home.domain.usecase.linesfavorites.AddStopFavoriteUseCase;
import com.sistemasolton.itranvias.home.domain.usecase.linesfavorites.DeleteStopFavoriteUseCase;
import com.sistemasolton.itranvias.home.domain.usecase.linesfavorites.GetAllStopsFavoriteUseCase;
import kotlin.Metadata;
import kotlin.ResultKt;
import kotlin.Unit;
import kotlin.coroutines.Continuation;
import kotlin.coroutines.intrinsics.IntrinsicsKt;
import kotlin.coroutines.jvm.internal.DebugMetadata;
import kotlin.coroutines.jvm.internal.SuspendLambda;
import kotlin.jvm.functions.Function2;
import kotlin.jvm.internal.Intrinsics;
import kotlin.text.StringsKt;
import kotlinx.coroutines.BuildersKt__Builders_commonKt;
import kotlinx.coroutines.CoroutineScope;

/* JADX INFO: compiled from: StopDetailViewModel.kt */
/* JADX INFO: loaded from: classes2.dex */
@Metadata(d1 = {"\u0000H\n\u0002\u0018\u0002\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0018\u0002\n\u0000\n\u0002\u0010\u000e\n\u0002\b\u0003\n\u0002\u0018\u0002\n\u0002\b\b\n\u0002\u0010\u0002\n\u0002\b\u0002\n\u0002\u0010\u000b\n\u0002\b\u0003\b\u0007\u0018\u00002\u00020\u0001B7\u0012\u0006\u0010\u0002\u001a\u00020\u0003\u0012\u0006\u0010\u0004\u001a\u00020\u0005\u0012\u0006\u0010\u0006\u001a\u00020\u0007\u0012\u0006\u0010\b\u001a\u00020\t\u0012\u0006\u0010\n\u001a\u00020\u000b\u0012\u0006\u0010\f\u001a\u00020\r¢\u0006\u0004\b\u000e\u0010\u000fJ\u0018\u0010\u0019\u001a\u00020\u001a2\u0006\u0010\u001b\u001a\u00020\r2\b\b\u0002\u0010\u001c\u001a\u00020\u001dJ\u0012\u0010\u001e\u001a\u00020\u001a2\n\b\u0002\u0010\u001f\u001a\u0004\u0018\u00010\rR\u000e\u0010\u0002\u001a\u00020\u0003X\u0082\u0004¢\u0006\u0002\n\u0000R\u000e\u0010\u0004\u001a\u00020\u0005X\u0082\u0004¢\u0006\u0002\n\u0000R\u000e\u0010\u0006\u001a\u00020\u0007X\u0082\u0004¢\u0006\u0002\n\u0000R\u000e\u0010\b\u001a\u00020\tX\u0082\u0004¢\u0006\u0002\n\u0000R\u000e\u0010\n\u001a\u00020\u000bX\u0082\u0004¢\u0006\u0002\n\u0000R\u000e\u0010\f\u001a\u00020\rX\u0082\u0004¢\u0006\u0002\n\u0000R+\u0010\u0012\u001a\u00020\u00112\u0006\u0010\u0010\u001a\u00020\u00118F@BX\u0086\u008e\u0002¢\u0006\u0012\n\u0004\b\u0017\u0010\u0018\u001a\u0004\b\u0013\u0010\u0014\"\u0004\b\u0015\u0010\u0016¨\u0006 "}, d2 = {"Lcom/sistemasolton/itranvias/home/presentation/stopdetail/StopDetailViewModel;", "Landroidx/lifecycle/ViewModel;", "getLocalInfoUseCase", "Lcom/sistemasolton/itranvias/home/domain/usecase/GetInfoLocalUseCase;", "getStopDetailUseCase", "Lcom/sistemasolton/itranvias/home/domain/usecase/GetStopDetailUseCase;", "getAllStopsFavoriteUseCase", "Lcom/sistemasolton/itranvias/home/domain/usecase/linesfavorites/GetAllStopsFavoriteUseCase;", "addStopFavoriteUseCase", "Lcom/sistemasolton/itranvias/home/domain/usecase/linesfavorites/AddStopFavoriteUseCase;", "deleteStopFavoriteUseCase", "Lcom/sistemasolton/itranvias/home/domain/usecase/linesfavorites/DeleteStopFavoriteUseCase;", "language", "", "<init>", "(Lcom/sistemasolton/itranvias/home/domain/usecase/GetInfoLocalUseCase;Lcom/sistemasolton/itranvias/home/domain/usecase/GetStopDetailUseCase;Lcom/sistemasolton/itranvias/home/domain/usecase/linesfavorites/GetAllStopsFavoriteUseCase;Lcom/sistemasolton/itranvias/home/domain/usecase/linesfavorites/AddStopFavoriteUseCase;Lcom/sistemasolton/itranvias/home/domain/usecase/linesfavorites/DeleteStopFavoriteUseCase;Ljava/lang/String;)V", "<set-?>", "Lcom/sistemasolton/itranvias/home/presentation/stopdetail/StopDetailState;", "state", "getState", "()Lcom/sistemasolton/itranvias/home/presentation/stopdetail/StopDetailState;", "setState", "(Lcom/sistemasolton/itranvias/home/presentation/stopdetail/StopDetailState;)V", "state$delegate", "Landroidx/compose/runtime/MutableState;", "loadInfo", "", "stopId", "showLoading", "", "toggleFavorite", "alias", "composeApp_release"}, k = 1, mv = {2, 1, 0}, xi = 48)
public final class StopDetailViewModel extends ViewModel {
    public static final int $stable = 8;
    private final AddStopFavoriteUseCase addStopFavoriteUseCase;
    private final DeleteStopFavoriteUseCase deleteStopFavoriteUseCase;
    private final GetAllStopsFavoriteUseCase getAllStopsFavoriteUseCase;
    private final GetInfoLocalUseCase getLocalInfoUseCase;
    private final GetStopDetailUseCase getStopDetailUseCase;
    private final String language;

    /* JADX INFO: renamed from: state$delegate, reason: from kotlin metadata */
    private final MutableState state;

    public StopDetailViewModel(GetInfoLocalUseCase getLocalInfoUseCase, GetStopDetailUseCase getStopDetailUseCase, GetAllStopsFavoriteUseCase getAllStopsFavoriteUseCase, AddStopFavoriteUseCase addStopFavoriteUseCase, DeleteStopFavoriteUseCase deleteStopFavoriteUseCase, String language) {
        Intrinsics.checkNotNullParameter(getLocalInfoUseCase, "getLocalInfoUseCase");
        Intrinsics.checkNotNullParameter(getStopDetailUseCase, "getStopDetailUseCase");
        Intrinsics.checkNotNullParameter(getAllStopsFavoriteUseCase, "getAllStopsFavoriteUseCase");
        Intrinsics.checkNotNullParameter(addStopFavoriteUseCase, "addStopFavoriteUseCase");
        Intrinsics.checkNotNullParameter(deleteStopFavoriteUseCase, "deleteStopFavoriteUseCase");
        Intrinsics.checkNotNullParameter(language, "language");
        this.getLocalInfoUseCase = getLocalInfoUseCase;
        this.getStopDetailUseCase = getStopDetailUseCase;
        this.getAllStopsFavoriteUseCase = getAllStopsFavoriteUseCase;
        this.addStopFavoriteUseCase = addStopFavoriteUseCase;
        this.deleteStopFavoriteUseCase = deleteStopFavoriteUseCase;
        this.language = language;
        this.state = SnapshotStateKt__SnapshotStateKt.mutableStateOf$default(new StopDetailState(false, false, null, null, null, false, null, 127, null), null, 2, null);
    }

    /* JADX INFO: Access modifiers changed from: private */
    public final void setState(StopDetailState stopDetailState) {
        this.state.setValue(stopDetailState);
    }

    /* JADX WARN: Multi-variable type inference failed */
    public final StopDetailState getState() {
        return (StopDetailState) this.state.getValue();
    }

    /* JADX INFO: renamed from: com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel$loadInfo$1, reason: invalid class name */
    /* JADX INFO: compiled from: StopDetailViewModel.kt */
    @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, 1, 0}, xi = 48)
    @DebugMetadata(c = "com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel$loadInfo$1", f = "StopDetailViewModel.kt", i = {0, 1}, l = {49, 73}, m = "invokeSuspend", n = {"success", "success"}, s = {"I$0", "I$0"})
    static final class AnonymousClass1 extends SuspendLambda implements Function2<CoroutineScope, Continuation<? super Unit>, Object> {
        final /* synthetic */ boolean $showLoading;
        final /* synthetic */ String $stopId;
        int I$0;
        int label;
        final /* synthetic */ StopDetailViewModel this$0;

        /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
        AnonymousClass1(boolean z, StopDetailViewModel stopDetailViewModel, String str, Continuation<? super AnonymousClass1> continuation) {
            super(2, continuation);
            this.$showLoading = z;
            this.this$0 = stopDetailViewModel;
            this.$stopId = str;
        }

        @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
        public final Continuation<Unit> create(Object obj, Continuation<?> continuation) {
            return new AnonymousClass1(this.$showLoading, this.this$0, this.$stopId, continuation);
        }

        @Override // kotlin.jvm.functions.Function2
        public final Object invoke(CoroutineScope coroutineScope, Continuation<? super Unit> continuation) {
            return ((AnonymousClass1) create(coroutineScope, continuation)).invokeSuspend(Unit.INSTANCE);
        }

        /* JADX WARN: Removed duplicated region for block: B:20:0x004b A[Catch: Exception -> 0x0024, TRY_ENTER, TRY_LEAVE, TryCatch #0 {Exception -> 0x0024, blocks: (B:20:0x004b, B:10:0x0020), top: B:29:0x0020 }] */
        /* JADX WARN: Unsupported multi-entry loop pattern (BACK_EDGE: B:25:0x00ab -> B:18:0x0048). Please report as a decompilation issue!!! */
        @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
        /*
            Code decompiled incorrectly, please refer to instructions dump.
            To view partially-correct code enable 'Show inconsistent code' option in preferences
        */
        public final java.lang.Object invokeSuspend(java.lang.Object r17) throws java.lang.Throwable {
            /*
                r16 = this;
                r1 = r16
                java.lang.Object r2 = kotlin.coroutines.intrinsics.IntrinsicsKt.getCOROUTINE_SUSPENDED()
                int r0 = r1.label
                r3 = 2
                r4 = 1
                if (r0 == 0) goto L29
                if (r0 == r4) goto L1e
                if (r0 != r3) goto L16
                int r0 = r1.I$0
                kotlin.ResultKt.throwOnFailure(r17)
                goto L48
            L16:
                java.lang.IllegalStateException r0 = new java.lang.IllegalStateException
                java.lang.String r2 = "call to 'resume' before 'invoke' with coroutine"
                r0.<init>(r2)
                throw r0
            L1e:
                int r5 = r1.I$0
                kotlin.ResultKt.throwOnFailure(r17)     // Catch: java.lang.Exception -> L24
                goto L6f
            L24:
                r0 = move-exception
                r15 = r5
                r5 = r0
                r0 = r15
                goto L71
            L29:
                kotlin.ResultKt.throwOnFailure(r17)
                boolean r0 = r1.$showLoading
                if (r0 == 0) goto L47
                com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel r0 = r1.this$0
                com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailState r5 = r0.getState()
                r13 = 116(0x74, float:1.63E-43)
                r14 = 0
                r6 = 1
                r7 = 0
                r8 = 0
                r9 = 0
                r10 = 0
                r11 = 0
                r12 = 0
                com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailState r5 = com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailState.copy$default(r5, r6, r7, r8, r9, r10, r11, r12, r13, r14)
                com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel.access$setState(r0, r5)
            L47:
                r0 = 0
            L48:
                r5 = r0
            L49:
                if (r5 != 0) goto Lae
                com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel r0 = r1.this$0     // Catch: java.lang.Exception -> L24
                com.sistemasolton.itranvias.home.domain.usecase.GetInfoLocalUseCase r0 = com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel.access$getGetLocalInfoUseCase$p(r0)     // Catch: java.lang.Exception -> L24
                kotlinx.coroutines.flow.Flow r0 = r0.invoke()     // Catch: java.lang.Exception -> L24
                com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel$loadInfo$1$1 r6 = new com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel$loadInfo$1$1     // Catch: java.lang.Exception -> L24
                com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel r7 = r1.this$0     // Catch: java.lang.Exception -> L24
                java.lang.String r8 = r1.$stopId     // Catch: java.lang.Exception -> L24
                r9 = 0
                r6.<init>(r7, r8, r9)     // Catch: java.lang.Exception -> L24
                kotlin.jvm.functions.Function2 r6 = (kotlin.jvm.functions.Function2) r6     // Catch: java.lang.Exception -> L24
                r7 = r1
                kotlin.coroutines.Continuation r7 = (kotlin.coroutines.Continuation) r7     // Catch: java.lang.Exception -> L24
                r1.I$0 = r5     // Catch: java.lang.Exception -> L24
                r1.label = r4     // Catch: java.lang.Exception -> L24
                java.lang.Object r0 = kotlinx.coroutines.flow.FlowKt.collectLatest(r0, r6, r7)     // Catch: java.lang.Exception -> L24
                if (r0 != r2) goto L6f
                return r2
            L6f:
                r5 = r4
                goto L49
            L71:
                java.lang.String r6 = r1.$stopId
                java.lang.String r7 = r5.getMessage()
                java.lang.StringBuilder r8 = new java.lang.StringBuilder
                java.lang.String r9 = "❌ Error al cargar detalles de la parada "
                r8.<init>(r9)
                java.lang.StringBuilder r6 = r8.append(r6)
                java.lang.String r8 = ": "
                java.lang.StringBuilder r6 = r6.append(r8)
                java.lang.StringBuilder r6 = r6.append(r7)
                java.lang.String r7 = ". Reintentando..."
                java.lang.StringBuilder r6 = r6.append(r7)
                java.lang.String r6 = r6.toString()
                java.io.PrintStream r7 = java.lang.System.out
                r7.println(r6)
                r5.printStackTrace()
                r5 = r1
                kotlin.coroutines.Continuation r5 = (kotlin.coroutines.Continuation) r5
                r1.I$0 = r0
                r1.label = r3
                r6 = 2000(0x7d0, double:9.88E-321)
                java.lang.Object r5 = kotlinx.coroutines.DelayKt.delay(r6, r5)
                if (r5 != r2) goto L48
                return r2
            Lae:
                kotlin.Unit r0 = kotlin.Unit.INSTANCE
                return r0
            */
            throw new UnsupportedOperationException("Method not decompiled: com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel.AnonymousClass1.invokeSuspend(java.lang.Object):java.lang.Object");
        }

        /* JADX INFO: renamed from: com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel$loadInfo$1$1, reason: invalid class name and collision with other inner class name */
        /* JADX INFO: compiled from: StopDetailViewModel.kt */
        @Metadata(d1 = {"\u0000\f\n\u0000\n\u0002\u0010\u0002\n\u0000\n\u0002\u0018\u0002\u0010\u0000\u001a\u00020\u00012\b\u0010\u0002\u001a\u0004\u0018\u00010\u0003H\n"}, d2 = {"<anonymous>", "", "infoDto", "Lcom/sistemasolton/itranvias/home/data/remote/dto/infodto/InfoDto;"}, k = 3, mv = {2, 1, 0}, xi = 48)
        @DebugMetadata(c = "com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel$loadInfo$1$1", f = "StopDetailViewModel.kt", i = {0, 1, 1}, l = {50, 51}, m = "invokeSuspend", n = {"infoDto", "infoDto", "detalle"}, s = {"L$0", "L$0", "L$1"})
        static final class C01221 extends SuspendLambda implements Function2<InfoDto, Continuation<? super Unit>, Object> {
            final /* synthetic */ String $stopId;
            /* synthetic */ Object L$0;
            Object L$1;
            int label;
            final /* synthetic */ StopDetailViewModel this$0;

            /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
            C01221(StopDetailViewModel stopDetailViewModel, String str, Continuation<? super C01221> continuation) {
                super(2, continuation);
                this.this$0 = stopDetailViewModel;
                this.$stopId = str;
            }

            @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
            public final Continuation<Unit> create(Object obj, Continuation<?> continuation) {
                C01221 c01221 = new C01221(this.this$0, this.$stopId, continuation);
                c01221.L$0 = obj;
                return c01221;
            }

            @Override // kotlin.jvm.functions.Function2
            public final Object invoke(InfoDto infoDto, Continuation<? super Unit> continuation) {
                return ((C01221) create(infoDto, continuation)).invokeSuspend(Unit.INSTANCE);
            }

            /* JADX WARN: Removed duplicated region for block: B:22:0x0083  */
            /* JADX WARN: Removed duplicated region for block: B:25:0x008d  */
            @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
            /*
                Code decompiled incorrectly, please refer to instructions dump.
                To view partially-correct code enable 'Show inconsistent code' option in preferences
            */
            public final java.lang.Object invokeSuspend(java.lang.Object r18) throws java.lang.Throwable {
                /*
                    Method dump skipped, instruction units count: 266
                    To view this dump change 'Code comments level' option to 'DEBUG'
                */
                throw new UnsupportedOperationException("Method not decompiled: com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel.AnonymousClass1.C01221.invokeSuspend(java.lang.Object):java.lang.Object");
            }
        }
    }

    public static /* synthetic */ void loadInfo$default(StopDetailViewModel stopDetailViewModel, String str, boolean z, int i, Object obj) {
        if ((i & 2) != 0) {
            z = true;
        }
        stopDetailViewModel.loadInfo(str, z);
    }

    public final void loadInfo(String stopId, boolean showLoading) {
        Intrinsics.checkNotNullParameter(stopId, "stopId");
        BuildersKt__Builders_commonKt.launch$default(ViewModelKt.getViewModelScope(this), null, null, new AnonymousClass1(showLoading, this, stopId, null), 3, null);
    }

    public static /* synthetic */ void toggleFavorite$default(StopDetailViewModel stopDetailViewModel, String str, int i, Object obj) {
        if ((i & 1) != 0) {
            str = null;
        }
        stopDetailViewModel.toggleFavorite(str);
    }

    public final void toggleFavorite(String alias) {
        BusesDto buses;
        DetalleParadaDto detalleParadaDto = getState().getDetalleParadaDto();
        if (detalleParadaDto == null || (buses = detalleParadaDto.getBuses()) == null) {
            return;
        }
        BuildersKt__Builders_commonKt.launch$default(ViewModelKt.getViewModelScope(this), null, null, new C06511(buses.getParada(), alias, null), 3, null);
    }

    /* JADX INFO: renamed from: com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel$toggleFavorite$1, reason: invalid class name and case insensitive filesystem */
    /* JADX INFO: compiled from: StopDetailViewModel.kt */
    @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, 1, 0}, xi = 48)
    @DebugMetadata(c = "com.sistemasolton.itranvias.home.presentation.stopdetail.StopDetailViewModel$toggleFavorite$1", f = "StopDetailViewModel.kt", i = {}, l = {86, 88}, m = "invokeSuspend", n = {}, s = {})
    static final class C06511 extends SuspendLambda implements Function2<CoroutineScope, Continuation<? super Unit>, Object> {
        final /* synthetic */ String $alias;
        final /* synthetic */ int $stopId;
        int label;

        /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
        C06511(int i, String str, Continuation<? super C06511> continuation) {
            super(2, continuation);
            this.$stopId = i;
            this.$alias = str;
        }

        @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
        public final Continuation<Unit> create(Object obj, Continuation<?> continuation) {
            return StopDetailViewModel.this.new C06511(this.$stopId, this.$alias, continuation);
        }

        @Override // kotlin.jvm.functions.Function2
        public final Object invoke(CoroutineScope coroutineScope, Continuation<? super Unit> continuation) {
            return ((C06511) create(coroutineScope, continuation)).invokeSuspend(Unit.INSTANCE);
        }

        @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl
        public final Object invokeSuspend(Object obj) throws Throwable {
            Object coroutine_suspended = IntrinsicsKt.getCOROUTINE_SUSPENDED();
            int i = this.label;
            try {
                if (i == 0) {
                    ResultKt.throwOnFailure(obj);
                    if (StopDetailViewModel.this.getState().isFavorite()) {
                        this.label = 1;
                        if (StopDetailViewModel.this.deleteStopFavoriteUseCase.invoke(String.valueOf(this.$stopId), this) == coroutine_suspended) {
                            return coroutine_suspended;
                        }
                    } else {
                        AddStopFavoriteUseCase addStopFavoriteUseCase = StopDetailViewModel.this.addStopFavoriteUseCase;
                        String strValueOf = String.valueOf(this.$stopId);
                        String str = this.$alias;
                        if (str == null || StringsKt.isBlank(str)) {
                            str = null;
                        }
                        this.label = 2;
                        if (addStopFavoriteUseCase.invoke(new StopFavoriteEntity(strValueOf, str), this) == coroutine_suspended) {
                            return coroutine_suspended;
                        }
                    }
                } else {
                    if (i != 1 && i != 2) {
                        throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
                    }
                    ResultKt.throwOnFailure(obj);
                }
                StopDetailViewModel stopDetailViewModel = StopDetailViewModel.this;
                stopDetailViewModel.setState(StopDetailState.copy$default(stopDetailViewModel.getState(), false, false, null, null, null, !StopDetailViewModel.this.getState().isFavorite(), null, 95, null));
            } catch (Exception e) {
                System.out.println((Object) ("Error al cambiar favorito: " + e.getMessage()));
                e.printStackTrace();
            }
            return Unit.INSTANCE;
        }
    }
}