Skip to content
This repository was archived by the owner on May 20, 2025. It is now read-only.

Commit 153ba26

Browse files
committed
added syncStatusCallback variable declaration
1 parent dd6ad91 commit 153ba26

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

CodePush.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -428,6 +428,8 @@ function codePushify(options = {}) {
428428
CodePush.notifyAppReady();
429429
} else {
430430
let rootComponentInstance = this.refs.rootComponent;
431+
432+
let syncStatusCallback;
431433
if (rootComponentInstance && rootComponentInstance.codePushStatusDidChange) {
432434
syncStatusCallback = rootComponentInstance.codePushStatusDidChange.bind(rootComponentInstance);
433435
}
@@ -436,7 +438,7 @@ function codePushify(options = {}) {
436438
if (rootComponentInstance && rootComponentInstance.codePushDownloadDidProgress) {
437439
downloadProgressCallback = rootComponentInstance.codePushDownloadDidProgress.bind(rootComponentInstance);
438440
}
439-
441+
440442
CodePush.sync(options, syncStatusCallback, downloadProgressCallback);
441443
if (options.checkFrequency === CodePush.CheckFrequency.ON_APP_RESUME) {
442444
ReactNative.AppState.addEventListener("change", (newState) => {

0 commit comments

Comments
 (0)