aries-askar GitHub
PR #211 | fix(js): promise handle error and rn updates |
Some additional updates after #209. It addresses two things: - also handle error code mismatch in the promise callback - update the RN implementation to handle the errors in the same way as we updated to in the node js wrapper. @berendsliedrecht you mentioned it was already implemented correctly in RN, were you talking about the unnessary error calling? Because the code matching logic was not present in the RN wrapper. I've changed the mismatch behaviour handling to now throw an error with the original errorCode, and a custom message "Error has already been overwritten, unable to provide error message". That way it won't break the calling implementation, as long as they use errorCodes to handle errors. I've looked and it seems we're not using error message from Askar anymore to do error handling, so this should fix the problem, except for not always having the correct error message in the logs. |
Created At 2023-12-21 08:01:12 +0000 UTC