package f5;

import Z6.InterfaceC0382w;
import a5.C0405d;
import android.content.SharedPreferences;
import com.google.android.gms.internal.measurement.C1;
import com.martsnew.data.model.request.UpdateUserInfoRequest;
import com.martsnew.data.model.response.LoginResponse;
import com.martsnew.data.model.response.UserResponse;
import d5.AbstractC0844a;
import e5.InterfaceC0881a;

/* JADX INFO: renamed from: f5.O, reason: case insensitive filesystem */
/* JADX INFO: loaded from: classes.dex */
public final class C0938O extends G6.i implements O6.p {

    /* JADX INFO: renamed from: u, reason: collision with root package name */
    public int f12754u;

    /* JADX INFO: renamed from: v, reason: collision with root package name */
    public final /* synthetic */ C0939P f12755v;

    /* JADX INFO: renamed from: w, reason: collision with root package name */
    public final /* synthetic */ Long f12756w;

    /* JADX INFO: renamed from: x, reason: collision with root package name */
    public final /* synthetic */ String f12757x;

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public C0938O(C0939P c0939p, Long l8, String str, E6.d dVar) {
        super(2, dVar);
        this.f12755v = c0939p;
        this.f12756w = l8;
        this.f12757x = str;
    }

    @Override // O6.p
    public final Object k(Object obj, Object obj2) {
        return ((C0938O) m((E6.d) obj2, (InterfaceC0382w) obj)).p(A6.n.f457a);
    }

    @Override // G6.a
    public final E6.d m(E6.d dVar, Object obj) {
        return new C0938O(this.f12755v, this.f12756w, this.f12757x, dVar);
    }

    @Override // G6.a
    public final Object p(Object obj) throws Throwable {
        F6.a aVar = F6.a.f2580q;
        int i = this.f12754u;
        C0939P c0939p = this.f12755v;
        if (i == 0) {
            C1.N(obj);
            InterfaceC0881a interfaceC0881a = c0939p.f12758a;
            String strL = AbstractC0844a.l(C1.v(c0939p.f12759b), g6.o.f12958a.g0());
            UpdateUserInfoRequest updateUserInfoRequest = new UpdateUserInfoRequest(this.f12756w, this.f12757x);
            this.f12754u = 1;
            obj = interfaceC0881a.s(strL, updateUserInfoRequest, this);
            if (obj == aVar) {
                return aVar;
            }
        } else {
            if (i != 1) {
                throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
            }
            C1.N(obj);
        }
        UserResponse userResponse = (UserResponse) obj;
        LoginResponse loginResponseA = c0939p.a();
        if (loginResponseA != null) {
            P6.g.e(userResponse, "<set-?>");
            loginResponseA.f10851a = userResponse;
        }
        C0405d c0405d = c0939p.f12759b;
        String strK = g6.o.f12958a.K();
        SharedPreferences.Editor editorEdit = c0405d.f7619a.edit();
        editorEdit.putString(strK, c0405d.f7620b.a(LoginResponse.class).d(loginResponseA));
        editorEdit.apply();
        return new X4.b(userResponse);
    }
}
