144 lines
8.6 KiB
Java
144 lines
8.6 KiB
Java
|
package com.discord.stores;
|
||
|
|
||
|
import android.content.Context;
|
||
|
import com.discord.api.guildscheduledevent.GuildScheduledEvent;
|
||
|
import com.discord.utilities.error.Error;
|
||
|
import com.discord.utilities.rest.RestAPI;
|
||
|
import com.discord.utilities.rx.ObservableExtensionsKt;
|
||
|
import d0.z.d.m;
|
||
|
import d0.z.d.o;
|
||
|
import kotlin.Unit;
|
||
|
import kotlin.jvm.functions.Function0;
|
||
|
import kotlin.jvm.functions.Function1;
|
||
|
/* compiled from: StoreGuildScheduledEvents.kt */
|
||
|
public final class StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 extends o implements Function0<Unit> {
|
||
|
public final /* synthetic */ long $eventId;
|
||
|
public final /* synthetic */ GuildScheduledEvent $storeEvent;
|
||
|
public final /* synthetic */ StoreGuildScheduledEvents this$0;
|
||
|
|
||
|
/* compiled from: StoreGuildScheduledEvents.kt */
|
||
|
/* renamed from: com.discord.stores.StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1$1 reason: invalid class name */
|
||
|
public static final class AnonymousClass1 extends o implements Function1<Error, Unit> {
|
||
|
public final /* synthetic */ StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 this$0;
|
||
|
|
||
|
/* JADX INFO: super call moved to the top of the method (can break code semantics) */
|
||
|
public AnonymousClass1(StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1) {
|
||
|
super(1);
|
||
|
this.this$0 = storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1;
|
||
|
}
|
||
|
|
||
|
/* Return type fixed from 'java.lang.Object' to match base method */
|
||
|
/* JADX DEBUG: Method arguments types fixed to match base method, original types: [java.lang.Object] */
|
||
|
@Override // kotlin.jvm.functions.Function1
|
||
|
public /* bridge */ /* synthetic */ Unit invoke(Error error) {
|
||
|
invoke(error);
|
||
|
return Unit.a;
|
||
|
}
|
||
|
|
||
|
public final void invoke(Error error) {
|
||
|
m.checkNotNullParameter(error, "it");
|
||
|
StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 = this.this$0;
|
||
|
StoreGuildScheduledEvents storeGuildScheduledEvents = storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1.this$0;
|
||
|
StoreGuildScheduledEvents.access$processRsvpCreate(storeGuildScheduledEvents, StoreGuildScheduledEvents.access$findEventFromStore(storeGuildScheduledEvents, storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1.$storeEvent));
|
||
|
StoreGuildScheduledEvents.access$getRsvpsAwaitingNetwork$p(this.this$0.this$0).remove(Long.valueOf(this.this$0.$eventId));
|
||
|
}
|
||
|
}
|
||
|
|
||
|
/* compiled from: StoreGuildScheduledEvents.kt */
|
||
|
/* renamed from: com.discord.stores.StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1$2 reason: invalid class name */
|
||
|
public static final class AnonymousClass2 extends o implements Function1<Void, Unit> {
|
||
|
public final /* synthetic */ StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 this$0;
|
||
|
|
||
|
/* JADX INFO: super call moved to the top of the method (can break code semantics) */
|
||
|
public AnonymousClass2(StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1) {
|
||
|
super(1);
|
||
|
this.this$0 = storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1;
|
||
|
}
|
||
|
|
||
|
/* Return type fixed from 'java.lang.Object' to match base method */
|
||
|
/* JADX DEBUG: Method arguments types fixed to match base method, original types: [java.lang.Object] */
|
||
|
@Override // kotlin.jvm.functions.Function1
|
||
|
public /* bridge */ /* synthetic */ Unit invoke(Void r1) {
|
||
|
invoke(r1);
|
||
|
return Unit.a;
|
||
|
}
|
||
|
|
||
|
public final void invoke(Void r3) {
|
||
|
StoreGuildScheduledEvents.access$getRsvpsAwaitingNetwork$p(this.this$0.this$0).remove(Long.valueOf(this.this$0.$eventId));
|
||
|
}
|
||
|
}
|
||
|
|
||
|
/* compiled from: StoreGuildScheduledEvents.kt */
|
||
|
/* renamed from: com.discord.stores.StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1$3 reason: invalid class name */
|
||
|
public static final class AnonymousClass3 extends o implements Function1<Error, Unit> {
|
||
|
public final /* synthetic */ StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 this$0;
|
||
|
|
||
|
/* JADX INFO: super call moved to the top of the method (can break code semantics) */
|
||
|
public AnonymousClass3(StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1) {
|
||
|
super(1);
|
||
|
this.this$0 = storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1;
|
||
|
}
|
||
|
|
||
|
/* Return type fixed from 'java.lang.Object' to match base method */
|
||
|
/* JADX DEBUG: Method arguments types fixed to match base method, original types: [java.lang.Object] */
|
||
|
@Override // kotlin.jvm.functions.Function1
|
||
|
public /* bridge */ /* synthetic */ Unit invoke(Error error) {
|
||
|
invoke(error);
|
||
|
return Unit.a;
|
||
|
}
|
||
|
|
||
|
public final void invoke(Error error) {
|
||
|
m.checkNotNullParameter(error, "it");
|
||
|
StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 = this.this$0;
|
||
|
StoreGuildScheduledEvents storeGuildScheduledEvents = storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1.this$0;
|
||
|
StoreGuildScheduledEvents.access$processRsvpDelete(storeGuildScheduledEvents, StoreGuildScheduledEvents.access$findEventFromStore(storeGuildScheduledEvents, storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1.$storeEvent));
|
||
|
StoreGuildScheduledEvents.access$getRsvpsAwaitingNetwork$p(this.this$0.this$0).remove(Long.valueOf(this.this$0.$eventId));
|
||
|
}
|
||
|
}
|
||
|
|
||
|
/* compiled from: StoreGuildScheduledEvents.kt */
|
||
|
/* renamed from: com.discord.stores.StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1$4 reason: invalid class name */
|
||
|
public static final class AnonymousClass4 extends o implements Function1<Unit, Unit> {
|
||
|
public final /* synthetic */ StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 this$0;
|
||
|
|
||
|
/* JADX INFO: super call moved to the top of the method (can break code semantics) */
|
||
|
public AnonymousClass4(StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1 storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1) {
|
||
|
super(1);
|
||
|
this.this$0 = storeGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1;
|
||
|
}
|
||
|
|
||
|
/* Return type fixed from 'java.lang.Object' to match base method */
|
||
|
/* JADX DEBUG: Method arguments types fixed to match base method, original types: [java.lang.Object] */
|
||
|
@Override // kotlin.jvm.functions.Function1
|
||
|
public /* bridge */ /* synthetic */ Unit invoke(Unit unit) {
|
||
|
invoke(unit);
|
||
|
return Unit.a;
|
||
|
}
|
||
|
|
||
|
public final void invoke(Unit unit) {
|
||
|
m.checkNotNullParameter(unit, "it");
|
||
|
StoreGuildScheduledEvents.access$getRsvpsAwaitingNetwork$p(this.this$0.this$0).remove(Long.valueOf(this.this$0.$eventId));
|
||
|
}
|
||
|
}
|
||
|
|
||
|
/* JADX INFO: super call moved to the top of the method (can break code semantics) */
|
||
|
public StoreGuildScheduledEvents$toggleRsvpGuildScheduledEvent$1(StoreGuildScheduledEvents storeGuildScheduledEvents, long j, GuildScheduledEvent guildScheduledEvent) {
|
||
|
super(0);
|
||
|
this.this$0 = storeGuildScheduledEvents;
|
||
|
this.$eventId = j;
|
||
|
this.$storeEvent = guildScheduledEvent;
|
||
|
}
|
||
|
|
||
|
@Override // kotlin.jvm.functions.Function0
|
||
|
/* renamed from: invoke */
|
||
|
public final void mo1invoke() {
|
||
|
if (StoreGuildScheduledEvents.access$getUserGuildScheduledEvents$p(this.this$0).keySet().contains(Long.valueOf(this.$eventId))) {
|
||
|
StoreGuildScheduledEvents.access$processRsvpDelete(this.this$0, this.$storeEvent);
|
||
|
ObservableExtensionsKt.appSubscribe$default(ObservableExtensionsKt.restSubscribeOn$default(RestAPI.Companion.getApi().deleteGuildScheduledEventRsvp(this.$storeEvent.d()), false, 1, null), this.this$0.getClass(), (Context) null, (Function1) null, new AnonymousClass1(this), (Function0) null, (Function0) null, new AnonymousClass2(this), 54, (Object) null);
|
||
|
return;
|
||
|
}
|
||
|
StoreGuildScheduledEvents.access$processRsvpCreate(this.this$0, this.$storeEvent);
|
||
|
ObservableExtensionsKt.appSubscribe$default(ObservableExtensionsKt.restSubscribeOn$default(RestAPI.Companion.getApi().createGuildScheduledEventRsvp(this.$storeEvent.d()), false, 1, null), this.this$0.getClass(), (Context) null, (Function1) null, new AnonymousClass3(this), (Function0) null, (Function0) null, new AnonymousClass4(this), 54, (Object) null);
|
||
|
}
|
||
|
}
|