mirror of
https://github.com/zhigang1992/react-native-code-push.git
synced 2026-05-14 02:14:52 +08:00
collapsed an if statement
This commit is contained in:
11
CodePush.js
11
CodePush.js
@@ -70,13 +70,10 @@ async function checkForUpdate(deploymentKey = null) {
|
||||
|
||||
return null;
|
||||
} else {
|
||||
if (Platform.OS === "android") {
|
||||
// Diff updates against the binary version not supported on Android
|
||||
if (!localPackage) {
|
||||
const binaryHash = await NativeCodePush.getBinaryHash();
|
||||
if (update.packageHash === binaryHash) {
|
||||
return null;
|
||||
}
|
||||
if (Platform.OS === "android" && !localPackage) {
|
||||
const binaryHash = await NativeCodePush.getBinaryHash();
|
||||
if (update.packageHash === binaryHash) {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user