Skip to content

Bugfix/deferred chain

username-removed-547784 requested to merge bugfix/deferredChain into master

The Promise chain is in fact a Deferred chain. However, the implementation of Promise::then() was incorrect as it relied on signals being emitted by the Promise. In case of intermediate Promises (e.g. when chaining two then() calls after another), the chain broke because the intermediate Promise is being destroyed before it emits the signals.

This MR fixes this by connecting to the signals of the Deferred created in Promise::then().

Merge request reports