diff --git a/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevServerHelper.java b/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevServerHelper.java index 69b22f49cfa75a..73d98a7631ef6e 100644 --- a/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevServerHelper.java +++ b/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevServerHelper.java @@ -19,6 +19,7 @@ import com.facebook.react.bridge.UiThreadUtil; import com.facebook.react.common.ReactConstants; import com.facebook.react.common.network.OkHttpCallUtil; +import com.facebook.react.devsupport.interfaces.DevBundleDownloadListener; import com.facebook.react.devsupport.interfaces.PackagerStatusCallback; import com.facebook.react.devsupport.interfaces.StackFrame; import com.facebook.react.modules.systeminfo.AndroidInfoHelpers; @@ -391,8 +392,10 @@ public String getInspectorAttachUrl(String title) { AndroidInfoHelpers.getFriendlyDeviceName()); } - public BundleDownloader getBundleDownloader() { - return mBundleDownloader; + public void downloadBundleFromURL( + DevBundleDownloadListener callback, + File outputFile, String bundleURL, BundleDownloader.BundleInfo bundleInfo) { + mBundleDownloader.downloadBundleFromURL(callback, outputFile, bundleURL, bundleInfo); } /** diff --git a/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevSupportManagerImpl.java b/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevSupportManagerImpl.java index b29f562f13b898..2af62749cd76eb 100644 --- a/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevSupportManagerImpl.java +++ b/ReactAndroid/src/main/java/com/facebook/react/devsupport/DevSupportManagerImpl.java @@ -1039,7 +1039,7 @@ public void reloadJSFromServer(final String bundleURL) { final BundleDownloader.BundleInfo bundleInfo = new BundleDownloader.BundleInfo(); - mDevServerHelper.getBundleDownloader().downloadBundleFromURL( + mDevServerHelper.downloadBundleFromURL( new DevBundleDownloadListener() { @Override public void onSuccess() {