fix: 修复数组越界闪退问题 https://sentry.shanqu.cc/organizations/lightgame/issues/372151/?query=is%3Aunresolved+assigned%3Ame&referrer=issue-stream&statsPeriod=14d
This commit is contained in:
@ -82,6 +82,7 @@ import java.util.ArrayList;
|
||||
import java.util.concurrent.atomic.AtomicBoolean;
|
||||
|
||||
import kotlin.Unit;
|
||||
import kotlin.collections.CollectionsKt;
|
||||
import kotlin.jvm.functions.Function0;
|
||||
|
||||
public class DialogUtils {
|
||||
@ -578,11 +579,15 @@ public class DialogUtils {
|
||||
dialog.dismiss();
|
||||
});
|
||||
|
||||
ApkEntity apkEntity = CollectionsKt.firstOrNull(gameEntity.getApk());
|
||||
String size = apkEntity == null ? "" : apkEntity.getSize();
|
||||
if ("show&download".equals(gameEntity.getOverseasAddressDialog().getStatus())) {
|
||||
gameEntity.getApk().get(0).setUrl(gameEntity.getOverseasAddressDialog().getLink());
|
||||
if (apkEntity != null) {
|
||||
apkEntity.setUrl(gameEntity.getOverseasAddressDialog().getLink());
|
||||
}
|
||||
}
|
||||
binding.urlTv.setText(gameEntity.getOverseasAddressDialog().getLink());
|
||||
binding.downloadBtn.setText("下载(" + gameEntity.getApk().get(0).getSize() + ")");
|
||||
binding.downloadBtn.setText("下载(" + size + ")");
|
||||
binding.downloadBtn.setOnClickListener(v -> {
|
||||
dismissByTouchInside.set(true);
|
||||
SensorsBridge.trackOverseasAddressDialogClick(
|
||||
|
||||
Reference in New Issue
Block a user