Function could, essentially equivalently, be const isolateErrors = async func => func(), basically as a more-self-documenting #1509—if anything I think in some browsers and circumstances that actually makes the error log better, compared to console.error, if I recall correctly.
Testing steps
You know... I'm not sure of a great way to reliably trigger the scenario to test this? I can maybe hack something together to ensure that modifiers get called in a certain order to demonstrate the problem. The place I ran into it was createCaughtUpLine throwing with a null input, per #1488, and breaking the boring tag chiclets tweak.
Description
Wraps callbacks passed to the mutations util in try-catch so they don't impact each other when they throw.
See https://github.com/AprilSylph/XKit-Rewritten/issues/1508.
Function could, essentially equivalently, be
const isolateErrors = async func => func()
, basically as a more-self-documenting #1509—if anything I think in some browsers and circumstances that actually makes the error log better, compared toconsole.error
, if I recall correctly.Testing steps
You know... I'm not sure of a great way to reliably trigger the scenario to test this? I can maybe hack something together to ensure that modifiers get called in a certain order to demonstrate the problem. The place I ran into it was
createCaughtUpLine
throwing with a null input, per #1488, and breaking the boring tag chiclets tweak.