(confirmPayload)
| 22 | resolveCallback(false) |
| 23 | } |
| 24 | const confirm = (confirmPayload) => { |
| 25 | dispatch({ |
| 26 | type: SHOW_CONFIRM, |
| 27 | payload: confirmPayload |
| 28 | }) |
| 29 | return new Promise((res) => { |
| 30 | resolveCallback = res |
| 31 | }) |
| 32 | } |
| 33 | |
| 34 | return { confirm, onConfirm, onCancel, confirmState } |
| 35 | } |
no outgoing calls
no test coverage detected