2021-08-09 22:50:52 +00:00
|
|
|
package com.discord.widgets.chat.overlay;
|
|
|
|
|
2021-12-17 22:01:24 +00:00
|
|
|
import b.d.b.a.a;
|
2021-08-09 22:50:52 +00:00
|
|
|
import com.discord.api.channel.Channel;
|
|
|
|
import com.discord.models.member.GuildMember;
|
|
|
|
import com.discord.models.user.User;
|
|
|
|
import com.discord.stores.StoreStream;
|
|
|
|
import com.discord.stores.StoreUser;
|
2021-11-01 07:19:03 +00:00
|
|
|
import d0.t.o;
|
|
|
|
import d0.z.d.m;
|
|
|
|
import j0.k.b;
|
2021-08-09 22:50:52 +00:00
|
|
|
import java.util.ArrayList;
|
|
|
|
import java.util.Collection;
|
|
|
|
import java.util.List;
|
|
|
|
import java.util.Map;
|
|
|
|
import java.util.Set;
|
|
|
|
import rx.Observable;
|
|
|
|
import rx.functions.Func2;
|
|
|
|
/* compiled from: ChatTypingModel.kt */
|
|
|
|
public final class ChatTypingModel$Companion$getTypingUsers$1<T, R> implements b<Set<? extends Long>, Observable<? extends List<? extends String>>> {
|
|
|
|
public final /* synthetic */ Channel $channel;
|
|
|
|
|
|
|
|
/* compiled from: ChatTypingModel.kt */
|
|
|
|
/* renamed from: com.discord.widgets.chat.overlay.ChatTypingModel$Companion$getTypingUsers$1$1 reason: invalid class name */
|
|
|
|
public static final class AnonymousClass1<T1, T2, R> implements Func2<Map<Long, ? extends User>, Map<Long, ? extends GuildMember>, List<? extends String>> {
|
|
|
|
public static final AnonymousClass1 INSTANCE = new AnonymousClass1();
|
|
|
|
|
|
|
|
/* 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, java.lang.Object] */
|
|
|
|
@Override // rx.functions.Func2
|
|
|
|
public /* bridge */ /* synthetic */ List<? extends String> call(Map<Long, ? extends User> map, Map<Long, ? extends GuildMember> map2) {
|
|
|
|
return call(map, (Map<Long, GuildMember>) map2);
|
|
|
|
}
|
|
|
|
|
|
|
|
public final List<String> call(Map<Long, ? extends User> map, Map<Long, GuildMember> map2) {
|
|
|
|
Collection<? extends User> values = map.values();
|
|
|
|
ArrayList arrayList = new ArrayList(o.collectionSizeOrDefault(values, 10));
|
|
|
|
for (T t : values) {
|
2021-08-31 07:21:49 +00:00
|
|
|
arrayList.add(GuildMember.Companion.getNickOrUsername((GuildMember) a.e(t, map2), t));
|
2021-08-09 22:50:52 +00:00
|
|
|
}
|
|
|
|
return arrayList;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
public ChatTypingModel$Companion$getTypingUsers$1(Channel channel) {
|
|
|
|
this.$channel = channel;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* 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] */
|
2021-11-01 07:19:03 +00:00
|
|
|
@Override // j0.k.b
|
2021-08-09 22:50:52 +00:00
|
|
|
public /* bridge */ /* synthetic */ Observable<? extends List<? extends String>> call(Set<? extends Long> set) {
|
|
|
|
return call((Set<Long>) set);
|
|
|
|
}
|
|
|
|
|
|
|
|
public final Observable<? extends List<String>> call(Set<Long> set) {
|
|
|
|
StoreStream.Companion companion = StoreStream.Companion;
|
|
|
|
StoreUser users = companion.getUsers();
|
|
|
|
m.checkNotNullExpressionValue(set, "userIds");
|
|
|
|
return Observable.j(users.observeUsers(set), companion.getGuilds().observeComputed(this.$channel.f(), set), AnonymousClass1.INSTANCE);
|
|
|
|
}
|
|
|
|
}
|