| 105 | |
| 106 | JSValueRef JSPromiseOnRejected::operator()(JSFunctionNativeCallContext& callContext) noexcept { |
| 107 | ScopedNativeCallActivity activity(getAttributingRuntime(callContext.getContext(), _anrAttribution), |
| 108 | _anrAttribution); |
| 109 | auto resolvedValue = JSValueRef::makeUnretained(callContext.getContext(), callContext.getParameter(0)); |
| 110 | auto error = convertJSErrorToValdiError(callContext.getContext(), resolvedValue, nullptr); |
| 111 | _callback->onFailure(std::move(error)); |
| 112 |