MOD限制规则(新)(修复重复安装不算更新的问题) https://git.shanqu.cc/pm/halo-app-issues/-/issues/1646
This commit is contained in:
@ -504,6 +504,20 @@ public class PackageUtils {
|
||||
return BuildConfig.VERSION_CODE;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取光环助手最后安装更新的时间
|
||||
*/
|
||||
public static long getHaloLastUpdateTime() {
|
||||
try {
|
||||
return HaloApp.getInstance().getApplication().getPackageManager()
|
||||
.getPackageInfo(BuildConfig.APPLICATION_ID, 0).lastUpdateTime;
|
||||
} catch (NameNotFoundException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* 获取apk的 versionName
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user