|
28 | 28 | import javax.annotation.Nullable;
|
29 | 29 | import okhttp3.Call;
|
30 | 30 | import okhttp3.Callback;
|
| 31 | +import okhttp3.Headers; |
31 | 32 | import okhttp3.OkHttpClient;
|
32 | 33 | import okhttp3.Request;
|
33 | 34 | import okhttp3.Response;
|
@@ -171,7 +172,7 @@ public void execute(Map<String, String> headers, Buffer body, boolean finished)
|
171 | 172 | if (headers.containsKey("X-Http-Status")) {
|
172 | 173 | status = Integer.parseInt(headers.get("X-Http-Status"));
|
173 | 174 | }
|
174 |
| - processBundleResult(url, status, okhttp3.Headers.of(headers), body, outputFile, bundleInfo, callback); |
| 175 | + processBundleResult(url, status, Headers.of(headers), body, outputFile, bundleInfo, callback); |
175 | 176 | } else {
|
176 | 177 | if (!headers.containsKey("Content-Type") || !headers.get("Content-Type").equals("application/json")) {
|
177 | 178 | return;
|
@@ -221,7 +222,7 @@ public void cancelDownloadBundleFromURL() {
|
221 | 222 | private void processBundleResult(
|
222 | 223 | String url,
|
223 | 224 | int statusCode,
|
224 |
| - okhttp3.Headers headers, |
| 225 | + Headers headers, |
225 | 226 | BufferedSource body,
|
226 | 227 | File outputFile,
|
227 | 228 | BundleInfo bundleInfo,
|
@@ -380,7 +381,7 @@ private static boolean isDeltaUrl(String bundleUrl) {
|
380 | 381 | return bundleUrl.indexOf(".delta?") != -1;
|
381 | 382 | }
|
382 | 383 |
|
383 |
| - private static void populateBundleInfo(String url, okhttp3.Headers headers, BundleInfo bundleInfo) { |
| 384 | + private static void populateBundleInfo(String url, Headers headers, BundleInfo bundleInfo) { |
384 | 385 | bundleInfo.mUrl = url;
|
385 | 386 |
|
386 | 387 | String filesChangedCountStr = headers.get("X-Metro-Files-Changed-Count");
|
|
0 commit comments