Previous Next

Switches the default context of the function to the context of the preceding promise, or the promise specified instead.


.applyCurrentContext( promise-func, context )

Promise-func is the function passed to one of the outcome functions of a Promise, typically a .then(), a .catch() or a .finally() clause.


The optional context overrides the current context directly with its value, e.g. “” or “ApplicationFrame”.


Omitting context will just execute the promise function with the context of its preceding promise.





    .then($.udb.applyCurrentContext(function() {


    }, set.context));