mirror of
https://gitcode.com/gh_mirrors/re/react-native-pushy.git
synced 2025-09-16 12:11:39 +08:00
prevent duplicated apk download
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "react-native-update",
|
"name": "react-native-update",
|
||||||
"version": "10.26.3",
|
"version": "10.26.4",
|
||||||
"description": "react-native hot update",
|
"description": "react-native hot update",
|
||||||
"main": "src/index",
|
"main": "src/index",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
@@ -181,7 +181,7 @@ export const UpdateProvider = ({
|
|||||||
setUpdateInfo(info);
|
setUpdateInfo(info);
|
||||||
if (info.expired) {
|
if (info.expired) {
|
||||||
const { downloadUrl } = info;
|
const { downloadUrl } = info;
|
||||||
if (downloadUrl) {
|
if (downloadUrl && Pushy.apkStatus === null) {
|
||||||
if (options.updateStrategy === 'silentAndNow') {
|
if (options.updateStrategy === 'silentAndNow') {
|
||||||
if (Platform.OS === 'android' && downloadUrl.endsWith('.apk')) {
|
if (Platform.OS === 'android' && downloadUrl.endsWith('.apk')) {
|
||||||
downloadAndInstallApk(downloadUrl);
|
downloadAndInstallApk(downloadUrl);
|
||||||
|
Reference in New Issue
Block a user