瀏覽代碼

Merge pull request #86 from francisco-sanchez-molina/patch-1

Lost content-length header fix
wkh237 8 年之前
父節點
當前提交
9f9f65bdab
共有 1 個文件被更改,包括 6 次插入1 次删除
  1. 6
    1
      src/android/src/main/java/com/RNFetchBlob/RNFetchBlobBody.java

+ 6
- 1
src/android/src/main/java/com/RNFetchBlob/RNFetchBlobBody.java 查看文件

@@ -59,7 +59,12 @@ public class RNFetchBlobBody extends RequestBody{
59 59
     public MediaType contentType() {
60 60
         return mime;
61 61
     }
62
-
62
+    
63
+    @Override
64
+    public long contentLength() {
65
+        return contentLength;
66
+    }
67
+    
63 68
     @Override
64 69
     public void writeTo(BufferedSink sink) throws IOException {
65 70