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.RegisterRequest;
import com.martsnew.data.model.response.LoginResponse;
import d5.AbstractC0844a;
import e5.InterfaceC0881a;

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

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

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

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

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

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

    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public C0937N(C0939P c0939p, String str, String str2, String str3, E6.d dVar) {
        super(2, dVar);
        this.f12750v = c0939p;
        this.f12751w = str;
        this.f12752x = str2;
        this.f12753y = str3;
    }

    @Override // O6.p
    public final Object k(Object obj, Object obj2) {
        return ((C0937N) 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 C0937N(this.f12750v, this.f12751w, this.f12752x, this.f12753y, dVar);
    }

    @Override // G6.a
    public final Object p(Object obj) throws Throwable {
        F6.a aVar = F6.a.f2580q;
        int i = this.f12749u;
        C0939P c0939p = this.f12750v;
        if (i == 0) {
            C1.N(obj);
            InterfaceC0881a interfaceC0881a = c0939p.f12758a;
            String strL = AbstractC0844a.l(C1.v(c0939p.f12759b), g6.o.f12958a.b0());
            RegisterRequest registerRequest = new RegisterRequest(this.f12751w, this.f12752x, this.f12753y);
            this.f12749u = 1;
            obj = interfaceC0881a.j(strL, registerRequest, this);
            if (obj == aVar) {
                return aVar;
            }
        } else {
            if (i != 1) {
                throw new IllegalStateException("call to 'resume' before 'invoke' with coroutine");
            }
            C1.N(obj);
        }
        LoginResponse loginResponse = (LoginResponse) obj;
        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(loginResponse));
        editorEdit.apply();
        return new X4.b(loginResponse);
    }
}
