mirror of
https://github.com/zhigang1992/react-native-code-push.git
synced 2026-05-14 02:14:52 +08:00
Update CodePush.js
This commit is contained in:
@@ -354,7 +354,11 @@ async function syncInternal(options = {}, syncStatusChangeCallback, downloadProg
|
||||
const dialogButtons = [{
|
||||
text: null,
|
||||
onPress: async () => {
|
||||
resolve(await doDownloadAndInstall());
|
||||
try {
|
||||
resolve(await doDownloadAndInstall());
|
||||
} catch (downloadError) {
|
||||
reject(downloadError);
|
||||
}
|
||||
}
|
||||
}];
|
||||
|
||||
@@ -451,4 +455,4 @@ if (NativeCodePush) {
|
||||
log("The CodePush module doesn't appear to be properly installed. Please double-check that everything is setup correctly.");
|
||||
}
|
||||
|
||||
module.exports = CodePush;
|
||||
module.exports = CodePush;
|
||||
|
||||
Reference in New Issue
Block a user