[android][storage] fix readable map already consumed error
This commit is contained in:
parent
bdf588e0e2
commit
90546aa7dd
|
@ -357,7 +357,11 @@ public class RNFirebaseStorage extends ReactContextBaseJavaModule {
|
|||
Log.d(TAG, "putFile success " + taskSnapshot);
|
||||
WritableMap resp = getUploadTaskAsMap(taskSnapshot);
|
||||
sendJSEvent(STORAGE_STATE_CHANGED, path, resp);
|
||||
|
||||
// to avoid readable map already consumed errors
|
||||
resp = getUploadTaskAsMap(taskSnapshot);
|
||||
sendJSEvent(STORAGE_UPLOAD_SUCCESS, path, resp);
|
||||
|
||||
resp = getUploadTaskAsMap(taskSnapshot);
|
||||
promise.resolve(resp);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue