Work with promise

Easy to emulate a complete hook function with Promise.prototype.finally()


Input

Picture

Output