From cda2db13b31b3144217c42e03ee88dfa7a3525b6 Mon Sep 17 00:00:00 2001 From: Geoffrey Goh Date: Wed, 24 Feb 2016 17:56:20 -0800 Subject: [PATCH] collapsed an if statement --- CodePush.js | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/CodePush.js b/CodePush.js index 8b993c6..a66f475 100644 --- a/CodePush.js +++ b/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; } }