package com.google.firebase.sessions.settings; import androidx.datastore.preferences.core.MutablePreferences; import androidx.datastore.preferences.core.Preferences; import kotlin.ResultKt; import kotlin.Unit; import kotlin.coroutines.Continuation; import kotlin.coroutines.intrinsics.IntrinsicsKt__IntrinsicsKt; import kotlin.coroutines.jvm.internal.SuspendLambda; import kotlin.jvm.functions.Function2; /* loaded from: classes3.dex */ public final class SettingsCache$updateConfigValue$2 extends SuspendLambda implements Function2 { public final /* synthetic */ Preferences.Key $key; public final /* synthetic */ Object $value; public /* synthetic */ Object L$0; public int label; public final /* synthetic */ SettingsCache this$0; /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */ public SettingsCache$updateConfigValue$2(Object obj, Preferences.Key key, SettingsCache settingsCache, Continuation continuation) { super(2, continuation); this.$value = obj; this.$key = key; this.this$0 = settingsCache; } @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl public final Continuation create(Object obj, Continuation continuation) { SettingsCache$updateConfigValue$2 settingsCache$updateConfigValue$2 = new SettingsCache$updateConfigValue$2(this.$value, this.$key, this.this$0, continuation); settingsCache$updateConfigValue$2.L$0 = obj; return settingsCache$updateConfigValue$2; } @Override // kotlin.jvm.functions.Function2 public final Object invoke(MutablePreferences mutablePreferences, Continuation continuation) { return ((SettingsCache$updateConfigValue$2) create(mutablePreferences, continuation)).invokeSuspend(Unit.INSTANCE); } @Override // kotlin.coroutines.jvm.internal.BaseContinuationImpl public final Object invokeSuspend(Object obj) { IntrinsicsKt__IntrinsicsKt.getCOROUTINE_SUSPENDED(); if (this.label == 0) { ResultKt.throwOnFailure(obj); MutablePreferences mutablePreferences = (MutablePreferences) this.L$0; Object obj2 = this.$value; if (obj2 != null) { mutablePreferences.set(this.$key, obj2); } else { mutablePreferences.remove(this.$key); } this.this$0.updateSessionConfigs(mutablePreferences); return Unit.INSTANCE; } throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine"); } }