* Fixes #12145 When transactions fail, preserve error message when presented with an error object. Fallback to stringified error for other cases. * Perserve error stack when err.stack is present, else set stack to message. * Use optional chaining