2019-02-04 20:08:30 +00:00
|
|
|
.class final Lcom/discord/widgets/servers/WidgetServerSettings$Model$Companion$get$1;
|
|
|
|
.super Ljava/lang/Object;
|
2019-02-04 20:29:01 +00:00
|
|
|
.source "WidgetServerSettings.kt"
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
# interfaces
|
|
|
|
.implements Lrx/functions/Func5;
|
|
|
|
|
|
|
|
|
|
|
|
# annotations
|
|
|
|
.annotation system Ldalvik/annotation/EnclosingMethod;
|
|
|
|
value = Lcom/discord/widgets/servers/WidgetServerSettings$Model$Companion;->get(J)Lrx/Observable;
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
.annotation system Ldalvik/annotation/InnerClass;
|
|
|
|
accessFlags = 0x18
|
|
|
|
name = null
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"<T1:",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
"T2:",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
"T3:",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
"T4:",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
"T5:",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
"R:",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
">",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
"Lrx/functions/Func5<",
|
|
|
|
"TT1;TT2;TT3;TT4;TT5;TR;>;"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
|
|
|
|
# static fields
|
|
|
|
.field public static final INSTANCE:Lcom/discord/widgets/servers/WidgetServerSettings$Model$Companion$get$1;
|
|
|
|
|
|
|
|
|
|
|
|
# direct methods
|
|
|
|
.method static constructor <clinit>()V
|
|
|
|
.locals 1
|
|
|
|
|
|
|
|
new-instance v0, Lcom/discord/widgets/servers/WidgetServerSettings$Model$Companion$get$1;
|
|
|
|
|
|
|
|
invoke-direct {v0}, Lcom/discord/widgets/servers/WidgetServerSettings$Model$Companion$get$1;-><init>()V
|
|
|
|
|
|
|
|
sput-object v0, Lcom/discord/widgets/servers/WidgetServerSettings$Model$Companion$get$1;->INSTANCE:Lcom/discord/widgets/servers/WidgetServerSettings$Model$Companion$get$1;
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method constructor <init>()V
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
|
|
|
|
# virtual methods
|
|
|
|
.method public final call(Lcom/discord/models/domain/ModelUser;Lcom/discord/models/domain/ModelGuild;Ljava/lang/Integer;Ljava/util/List;Ljava/util/Map;)Lcom/discord/widgets/servers/WidgetServerSettings$Model;
|
2019-02-14 22:50:29 +00:00
|
|
|
.locals 19
|
2019-02-04 20:08:30 +00:00
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"(",
|
|
|
|
"Lcom/discord/models/domain/ModelUser;",
|
|
|
|
"Lcom/discord/models/domain/ModelGuild;",
|
|
|
|
"Ljava/lang/Integer;",
|
|
|
|
"Ljava/util/List<",
|
|
|
|
"+",
|
|
|
|
"Lcom/discord/models/domain/ModelChannel;",
|
|
|
|
">;",
|
|
|
|
"Ljava/util/Map<",
|
|
|
|
"Ljava/lang/Long;",
|
|
|
|
"Ljava/lang/Integer;",
|
|
|
|
">;)",
|
|
|
|
"Lcom/discord/widgets/servers/WidgetServerSettings$Model;"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
move-object/from16 v7, p3
|
|
|
|
|
|
|
|
move-object/from16 v0, p4
|
|
|
|
|
|
|
|
if-nez p2, :cond_0
|
|
|
|
|
|
|
|
const/4 v0, 0x0
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
const-string v1, "categories"
|
|
|
|
|
|
|
|
invoke-static {v0, v1}, Lkotlin/jvm/internal/j;->g(Ljava/lang/Object;Ljava/lang/String;)V
|
|
|
|
|
|
|
|
check-cast v0, Ljava/lang/Iterable;
|
|
|
|
|
|
|
|
instance-of v1, v0, Ljava/util/Collection;
|
|
|
|
|
|
|
|
const/16 v2, 0x10
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
const/4 v8, 0x1
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
const/4 v9, 0x0
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
if-eqz v1, :cond_1
|
|
|
|
|
|
|
|
move-object v1, v0
|
|
|
|
|
|
|
|
check-cast v1, Ljava/util/Collection;
|
|
|
|
|
|
|
|
invoke-interface {v1}, Ljava/util/Collection;->isEmpty()Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-nez v1, :cond_3
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
invoke-interface {v0}, Ljava/lang/Iterable;->iterator()Ljava/util/Iterator;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
invoke-interface {v0}, Ljava/util/Iterator;->hasNext()Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-eqz v1, :cond_3
|
|
|
|
|
|
|
|
invoke-interface {v0}, Ljava/util/Iterator;->next()Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
check-cast v1, Lcom/discord/models/domain/ModelChannel;
|
|
|
|
|
|
|
|
invoke-virtual {v1}, Lcom/discord/models/domain/ModelChannel;->getId()J
|
|
|
|
|
|
|
|
move-result-wide v3
|
|
|
|
|
|
|
|
invoke-static {v3, v4}, Ljava/lang/Long;->valueOf(J)Ljava/lang/Long;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
move-object/from16 v3, p5
|
|
|
|
|
|
|
|
invoke-interface {v3, v1}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
check-cast v1, Ljava/lang/Integer;
|
|
|
|
|
|
|
|
invoke-static {v2, v1}, Lcom/discord/utilities/permissions/PermissionUtils;->can(ILjava/lang/Integer;)Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-eqz v1, :cond_2
|
|
|
|
|
|
|
|
const/4 v0, 0x1
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_3
|
|
|
|
const/4 v0, 0x0
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
const-string v1, "me"
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move-object/from16 v10, p1
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
invoke-static {v10, v1}, Lkotlin/jvm/internal/j;->g(Ljava/lang/Object;Ljava/lang/String;)V
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/models/domain/ModelUser;->isMfaEnabled()Z
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move-result v11
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/models/domain/ModelGuild;->getMfaLevel()I
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move-result v12
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/models/domain/ModelGuild;->getOwnerId()J
|
|
|
|
|
|
|
|
move-result-wide v3
|
|
|
|
|
|
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/models/domain/ModelUser;->getId()J
|
|
|
|
|
|
|
|
move-result-wide v5
|
|
|
|
|
|
|
|
cmp-long v1, v3, v5
|
|
|
|
|
|
|
|
if-nez v1, :cond_4
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
const/4 v13, 0x1
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_4
|
2019-02-04 20:29:01 +00:00
|
|
|
const/4 v13, 0x0
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
:goto_1
|
2019-02-04 20:29:01 +00:00
|
|
|
if-nez v13, :cond_6
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
const/16 v1, 0x20
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
invoke-static {v1, v7, v11, v12}, Lcom/discord/utilities/permissions/PermissionUtils;->canAndIsElevated(ILjava/lang/Integer;ZI)Z
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-eqz v1, :cond_5
|
|
|
|
|
|
|
|
goto :goto_2
|
|
|
|
|
|
|
|
:cond_5
|
2019-02-04 20:29:01 +00:00
|
|
|
const/4 v14, 0x0
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
goto :goto_3
|
|
|
|
|
|
|
|
:cond_6
|
|
|
|
:goto_2
|
2019-02-04 20:29:01 +00:00
|
|
|
const/4 v14, 0x1
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
:goto_3
|
2019-02-04 20:29:01 +00:00
|
|
|
if-nez v13, :cond_8
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
invoke-static {v2, v7, v11, v12}, Lcom/discord/utilities/permissions/PermissionUtils;->canAndIsElevated(ILjava/lang/Integer;ZI)Z
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-nez v1, :cond_8
|
|
|
|
|
|
|
|
if-eqz v0, :cond_7
|
|
|
|
|
|
|
|
goto :goto_4
|
|
|
|
|
|
|
|
:cond_7
|
2019-02-04 20:29:01 +00:00
|
|
|
const/4 v15, 0x0
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
goto :goto_5
|
|
|
|
|
|
|
|
:cond_8
|
|
|
|
:goto_4
|
2019-02-04 20:29:01 +00:00
|
|
|
const/4 v15, 0x1
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
:goto_5
|
2019-02-04 20:29:01 +00:00
|
|
|
if-nez v13, :cond_a
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
const/high16 v0, 0x10000000
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
invoke-static {v0, v7, v11, v12}, Lcom/discord/utilities/permissions/PermissionUtils;->canAndIsElevated(ILjava/lang/Integer;ZI)Z
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
|
|
|
if-eqz v0, :cond_9
|
|
|
|
|
|
|
|
goto :goto_6
|
|
|
|
|
|
|
|
:cond_9
|
2019-02-04 20:29:01 +00:00
|
|
|
const/16 v16, 0x0
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
goto :goto_7
|
|
|
|
|
|
|
|
:cond_a
|
|
|
|
:goto_6
|
2019-02-04 20:29:01 +00:00
|
|
|
const/16 v16, 0x1
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
:goto_7
|
2019-02-04 20:29:01 +00:00
|
|
|
if-nez v13, :cond_c
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
const/4 v0, 0x4
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
invoke-static {v0, v7, v11, v12}, Lcom/discord/utilities/permissions/PermissionUtils;->canAndIsElevated(ILjava/lang/Integer;ZI)Z
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
|
|
|
if-eqz v0, :cond_b
|
|
|
|
|
|
|
|
goto :goto_8
|
|
|
|
|
|
|
|
:cond_b
|
2019-02-04 20:29:01 +00:00
|
|
|
const/16 v17, 0x0
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
goto :goto_9
|
|
|
|
|
|
|
|
:cond_c
|
|
|
|
:goto_8
|
2019-02-04 20:29:01 +00:00
|
|
|
const/16 v17, 0x1
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
:goto_9
|
2019-02-04 20:29:01 +00:00
|
|
|
if-nez v13, :cond_e
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-14 22:50:29 +00:00
|
|
|
const/high16 v0, 0x40000000 # 2.0f
|
|
|
|
|
|
|
|
invoke-static {v0, v7, v11, v12}, Lcom/discord/utilities/permissions/PermissionUtils;->canAndIsElevated(ILjava/lang/Integer;ZI)Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
|
|
|
if-eqz v0, :cond_d
|
|
|
|
|
|
|
|
goto :goto_a
|
|
|
|
|
|
|
|
:cond_d
|
|
|
|
const/16 v18, 0x0
|
|
|
|
|
|
|
|
goto :goto_b
|
|
|
|
|
|
|
|
:cond_e
|
|
|
|
:goto_a
|
|
|
|
const/16 v18, 0x1
|
|
|
|
|
|
|
|
:goto_b
|
|
|
|
if-nez v13, :cond_10
|
|
|
|
|
2019-02-04 20:08:30 +00:00
|
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/models/domain/ModelUser;->getId()J
|
|
|
|
|
|
|
|
move-result-wide v0
|
|
|
|
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/models/domain/ModelGuild;->getOwnerId()J
|
|
|
|
|
|
|
|
move-result-wide v3
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move v2, v11
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move v5, v12
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
move-object/from16 v6, p3
|
|
|
|
|
|
|
|
invoke-static/range {v0 .. v6}, Lcom/discord/utilities/permissions/PermissionUtils;->canManageGuildMembers(JZJILjava/lang/Integer;)Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
2019-02-14 22:50:29 +00:00
|
|
|
if-eqz v0, :cond_f
|
2019-02-04 20:29:01 +00:00
|
|
|
|
2019-02-14 22:50:29 +00:00
|
|
|
goto :goto_c
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-14 22:50:29 +00:00
|
|
|
:cond_f
|
2019-02-04 20:29:01 +00:00
|
|
|
const/4 v8, 0x0
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-14 22:50:29 +00:00
|
|
|
:cond_10
|
|
|
|
:goto_c
|
2019-02-04 20:08:30 +00:00
|
|
|
invoke-virtual/range {p1 .. p1}, Lcom/discord/models/domain/ModelUser;->getId()J
|
|
|
|
|
|
|
|
move-result-wide v0
|
|
|
|
|
|
|
|
invoke-virtual/range {p2 .. p2}, Lcom/discord/models/domain/ModelGuild;->getOwnerId()J
|
|
|
|
|
|
|
|
move-result-wide v3
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move v2, v11
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move v5, v12
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
move-object/from16 v6, p3
|
|
|
|
|
|
|
|
invoke-static/range {v0 .. v6}, Lcom/discord/utilities/permissions/PermissionUtils;->canViewAuditLogs(JZJILjava/lang/Integer;)Z
|
|
|
|
|
|
|
|
move-result v9
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
new-instance v10, Lcom/discord/widgets/servers/WidgetServerSettings$Model;
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move-object v0, v10
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
move-object/from16 v1, p2
|
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move v2, v13
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move v3, v14
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move v4, v15
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move/from16 v5, v16
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move/from16 v6, v17
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
move v7, v8
|
2019-02-04 20:08:30 +00:00
|
|
|
|
|
|
|
move v8, v9
|
|
|
|
|
2019-02-14 22:50:29 +00:00
|
|
|
move/from16 v9, v18
|
|
|
|
|
|
|
|
invoke-direct/range {v0 .. v9}, Lcom/discord/widgets/servers/WidgetServerSettings$Model;-><init>(Lcom/discord/models/domain/ModelGuild;ZZZZZZZZ)V
|
2019-02-04 20:08:30 +00:00
|
|
|
|
2019-02-04 20:29:01 +00:00
|
|
|
return-object v10
|
2019-02-04 20:08:30 +00:00
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public final bridge synthetic call(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
check-cast p1, Lcom/discord/models/domain/ModelUser;
|
|
|
|
|
|
|
|
check-cast p2, Lcom/discord/models/domain/ModelGuild;
|
|
|
|
|
|
|
|
check-cast p3, Ljava/lang/Integer;
|
|
|
|
|
|
|
|
check-cast p4, Ljava/util/List;
|
|
|
|
|
|
|
|
check-cast p5, Ljava/util/Map;
|
|
|
|
|
|
|
|
invoke-virtual/range {p0 .. p5}, Lcom/discord/widgets/servers/WidgetServerSettings$Model$Companion$get$1;->call(Lcom/discord/models/domain/ModelUser;Lcom/discord/models/domain/ModelGuild;Ljava/lang/Integer;Ljava/util/List;Ljava/util/Map;)Lcom/discord/widgets/servers/WidgetServerSettings$Model;
|
|
|
|
|
|
|
|
move-result-object p1
|
|
|
|
|
|
|
|
return-object p1
|
|
|
|
.end method
|