From 6130fa345b320ef28691d080e9b35dbd8d4e2866 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8F=B6=E5=AD=90=E7=BB=B4?= Date: Mon, 1 Apr 2024 10:18:01 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E5=BF=AB=E6=8D=B7?= =?UTF-8?q?=E6=96=B9=E5=BC=8F=E5=90=AF=E5=8A=A8=E6=A8=A1=E6=8B=9F=E5=99=A8?= =?UTF-8?q?=E6=B8=B8=E6=88=8F=E5=87=BA=E7=8E=B0=E7=9A=84=E9=97=AA=E9=80=80?= =?UTF-8?q?=E9=97=AE=E9=A2=98=20https://sentry.shanqu.cc/organizations/lig?= =?UTF-8?q?htgame/issues/376360/events/7240c5329d03408dba143ffb3fc8213a/?= =?UTF-8?q?=3Fproject=3D22?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/com/gh/gamecenter/entity/GameUpdateEntity.kt | 9 +++------ .../java/com/gh/gamecenter/feature/entity/GameEntity.kt | 7 +++---- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/app/src/main/java/com/gh/gamecenter/entity/GameUpdateEntity.kt b/app/src/main/java/com/gh/gamecenter/entity/GameUpdateEntity.kt index e34e28d78e..16f5f73568 100644 --- a/app/src/main/java/com/gh/gamecenter/entity/GameUpdateEntity.kt +++ b/app/src/main/java/com/gh/gamecenter/entity/GameUpdateEntity.kt @@ -2,12 +2,10 @@ package com.gh.gamecenter.entity import com.gh.gamecenter.common.constant.Constants import com.gh.gamecenter.common.entity.IconFloat -import com.gh.gamecenter.feature.exposure.ExposureEvent import com.gh.gamecenter.feature.entity.* +import com.gh.gamecenter.feature.exposure.ExposureEvent import com.google.gson.annotations.SerializedName -import kotlinx.parcelize.IgnoredOnParcel import java.util.* -import kotlin.collections.ArrayList data class GameUpdateEntity( @SerializedName("game_id") @@ -76,9 +74,8 @@ data class GameUpdateEntity( /** * 是否为 mod 游戏,根据是否有 mod 标签来判断,不受镜像、游戏屏蔽影响 */ - val isModdedGame by lazy { - tagStyle.any { it.name.lowercase(Locale.getDefault()) == "mod" } - } + val isModdedGame: Boolean + get() = tagStyle.any { it.name.lowercase(Locale.getDefault()) == "mod" } fun isShowPlugin(location: PluginLocation): Boolean { diff --git a/module_core_feature/src/main/java/com/gh/gamecenter/feature/entity/GameEntity.kt b/module_core_feature/src/main/java/com/gh/gamecenter/feature/entity/GameEntity.kt index d9d0377aa4..39f091580e 100644 --- a/module_core_feature/src/main/java/com/gh/gamecenter/feature/entity/GameEntity.kt +++ b/module_core_feature/src/main/java/com/gh/gamecenter/feature/entity/GameEntity.kt @@ -9,7 +9,7 @@ import com.gh.gamecenter.common.entity.CommunityEntity import com.gh.gamecenter.common.entity.Display import com.gh.gamecenter.common.entity.IconFloat import com.gh.gamecenter.common.entity.LinkEntity -import com.gh.gamecenter.core.provider.* +import com.gh.gamecenter.core.provider.IAppProvider import com.gh.gamecenter.feature.HaloApp import com.gh.gamecenter.feature.R import com.gh.gamecenter.feature.exposure.ExposureEvent @@ -577,9 +577,8 @@ data class GameEntity( * 是否为 mod 游戏,根据是否有 mod 标签来判断,不受镜像、游戏屏蔽影响 */ @IgnoredOnParcel - val isModdedGame by lazy { - mTagStyle.any { it.name.lowercase(Locale.getDefault()) == "mod" } - } + val isModdedGame: Boolean + get() = mTagStyle.any { it.name.lowercase(Locale.getDefault()) == "mod" } @IgnoredOnParcel val downloadAddWord: String?