davecoates / rn-firebase-bridge

React Native Firebase Bridge
59 stars 8 forks source link

Handling errors in once method #25

Closed Paul-Todd closed 8 years ago

Paul-Todd commented 8 years ago

Should the "func on" and "func once" methods have "withCancelBlock" extensions in their "observeSingleEventOfType"/ "observeEventType" helpers.

I got a promise being unfulfilled because the backend was returning permission denied and it was not being handled because the "withBlock" was not called.

Paul-Todd commented 8 years ago

For now I have fixed the permissions problem on the backend but there are other cases I can think of where the response could be interrupted and would need handling.

davecoates commented 8 years ago

Ah yes - you are correct

Will have a fix soon

davecoates commented 8 years ago

Available 0.1.1