mirror of
https://github.com/status-im/react-native-camera.git
synced 2025-02-24 09:48:17 +00:00
If a user of the library called `capture` too early then it tries to get the device orientation from the RCTCamera instance... which doesn't yet exist. Instead of adding anything clever in the library, just call promise.reject() so that the host application can decide what to do with this issue (probably wait, retry in a bit). This mainly effects slower Android devices where the camera can take a long time to initialize.