41 lines
1.9 KiB
Java
41 lines
1.9 KiB
Java
package com.discord.widgets.servers.auditlog;
|
|
|
|
import com.discord.models.user.User;
|
|
import com.discord.utilities.search.SearchUtils;
|
|
import d0.z.d.m;
|
|
import d0.z.d.o;
|
|
import java.util.Objects;
|
|
import kotlin.jvm.functions.Function1;
|
|
/* compiled from: WidgetServerSettingsAuditLogFilterSheet.kt */
|
|
public final class WidgetServerSettingsAuditLogFilterSheet$Model$Companion$get$2$listItems$1 extends o implements Function1<User, Boolean> {
|
|
public final /* synthetic */ String $filterText;
|
|
|
|
/* JADX INFO: super call moved to the top of the method (can break code semantics) */
|
|
public WidgetServerSettingsAuditLogFilterSheet$Model$Companion$get$2$listItems$1(String str) {
|
|
super(1);
|
|
this.$filterText = str;
|
|
}
|
|
|
|
/* 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 */ Boolean invoke(User user) {
|
|
return Boolean.valueOf(invoke(user));
|
|
}
|
|
|
|
public final boolean invoke(User user) {
|
|
m.checkNotNullParameter(user, "it");
|
|
SearchUtils searchUtils = SearchUtils.INSTANCE;
|
|
String str = this.$filterText;
|
|
m.checkNotNullExpressionValue(str, "filterText");
|
|
Objects.requireNonNull(str, "null cannot be cast to non-null type java.lang.String");
|
|
String lowerCase = str.toLowerCase();
|
|
m.checkNotNullExpressionValue(lowerCase, "(this as java.lang.String).toLowerCase()");
|
|
String username = user.getUsername();
|
|
Objects.requireNonNull(username, "null cannot be cast to non-null type java.lang.String");
|
|
String lowerCase2 = username.toLowerCase();
|
|
m.checkNotNullExpressionValue(lowerCase2, "(this as java.lang.String).toLowerCase()");
|
|
return searchUtils.fuzzyMatch(lowerCase, lowerCase2);
|
|
}
|
|
}
|