I am trying to pass a bytearray object through Promise to the Javascript in react - native.

**Code:**

```
  RawRequest request = new RawRequest(Request.Method.GET, path, new 

 ResponseListener<byte[]>() {

        @Override
        public void onResponse(byte[] bytes) {

           //Let's pass the response in the form of bytes
             promise.resolve(bytes);

    Log.d(TAG,"The response in bytes length is " + bytes.length);
        }

    }, new ErrorListener() {
        @Override
        public void onError(HttpError httpError) {

        }
    })

```

**Exception:**

FATAL EXCEPTION: main
 Process: com.listviewdbproject, PID: 5965
 java.lang.RuntimeException: Cannot convert argument of type class [B
 at com.facebook.react.bridge.Arguments.fromJavaArgs(Arguments.java:57)
 at com.facebook.react.bridge.CallbackImpl.invoke(CallbackImpl.java:29)
 at com.facebook.react.bridge.PromiseImpl.resolve(PromiseImpl.java:32)
 at com.example.creosdk.HttpModule$1.onResponse(HttpModule.java:80)
 at com.example.creosdk.HttpModule$1.onResponse(HttpModule.java:76)
 at com.creo.fuel.uttp.http.toolbox.RawRequest.deliverResponse(RawRequest.java:46)
 at com.creo.fuel.uttp.http.toolbox.RawRequest.deliverResponse(RawRequest.java:16)
 at com.creo.fuel.uttp.http.delivery.ExecutorDelivery$ResponseDeliveryRunnable.run(ExecutorDelivery.java:100)
 at android.os.Handler.handleCallback(Handler.java:815)
 at android.os.Handler.dispatchMessage(Handler.java:104)
 at android.os.Looper.loop(Looper.java:194)
 at android.app.ActivityThread.main(ActivityThread.java:5616)
 at java.lang.reflect.Method.invoke(Native Method)
 at java.lang.reflect.Method.invoke(Method.java:372)
 at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:959)
 at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:754)