mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-03-26 07:04:05 +08:00
Updated RCTPromiseRejectBlock example to use new 3 argument form
Reviewed By: svcscm Differential Revision: D2931949 fb-gh-sync-id: d5da545c882e662f9c5d5b33cc3b152a4269bbb8 shipit-source-id: d5da545c882e662f9c5d5b33cc3b152a4269bbb8
This commit is contained in:
committed by
facebook-github-bot-5
parent
a7521a23ae
commit
b5579e807e
@@ -188,7 +188,8 @@ RCT_REMAP_METHOD(findEvents,
|
||||
if (events) {
|
||||
resolve(events);
|
||||
} else {
|
||||
reject(error);
|
||||
NSError *error = ...
|
||||
reject(@"no_events", @"There were no events", error);
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user