Trying to bridge the first barrier of Haskell learners through already familiar JavaScript
Resolve / reject a Promise from outside, after return