File tree Expand file tree Collapse file tree 1 file changed +0
-4
lines changed
android/src/main/java/com/RNFetchBlob Expand file tree Collapse file tree 1 file changed +0
-4
lines changed Original file line number Diff line number Diff line change 21
21
import com .facebook .react .modules .core .DeviceEventManagerModule ;
22
22
23
23
import java .io .*;
24
- import java .nio .ByteBuffer ;
25
24
import java .nio .charset .Charset ;
26
- import java .nio .charset .CharsetEncoder ;
27
25
import java .security .MessageDigest ;
28
26
import java .util .ArrayList ;
29
27
import java .util .HashMap ;
@@ -325,9 +323,7 @@ else if(resolved == null) {
325
323
boolean error = false ;
326
324
327
325
if (encoding .equalsIgnoreCase ("utf8" )) {
328
- CharsetEncoder encoder = Charset .forName ("UTF-8" ).newEncoder ();
329
326
while ((cursor = fs .read (buffer )) != -1 ) {
330
- encoder .encode (ByteBuffer .wrap (buffer ).asCharBuffer ());
331
327
String chunk = new String (buffer , 0 , cursor );
332
328
emitStreamEvent (streamId , "data" , chunk );
333
329
if (tick > 0 )
You can’t perform that action at this time.
0 commit comments