Closed timkinnane closed 6 years ago
The executePiece could wrap calling done() in a Promise.resolve, allowing IPieceDone interface to accept functions resolving with Promise<void>|void.
executePiece
done()
Promise.resolve
IPieceDone
Promise<void>|void
Then update tests that use () => Promise.resolve() to just () => null.
() => Promise.resolve()
() => null
see https://github.com/Amazebot/bbot/blob/master/src/adapters/mongo.ts#L120
The
executePiece
could wrap callingdone()
in aPromise.resolve
, allowingIPieceDone
interface to accept functions resolving withPromise<void>|void
.Then update tests that use
() => Promise.resolve()
to just() => null
.see https://github.com/Amazebot/bbot/blob/master/src/adapters/mongo.ts#L120