The optional chaining of the controller.abort('update') calls in injectPromise() are causing builds to extract the abort function to its own variable, losing the controllerthis scope when invoked. This causes an Illegal invocation error.
Use an if statement instead and change the type cast location to match the other controller.abort() call.
Description
The optional chaining of the
controller.abort('update')
calls ininjectPromise()
are causing builds to extract theabort
function to its own variable, losing thecontroller
this
scope when invoked. This causes anIllegal invocation
error.Use an if statement instead and change the type cast location to match the other
controller.abort()
call.