Closed MartinSahlen closed 5 years ago
Hey @MartinSahlen, thank you for the interest in the module! It is a reasonable request, I see logic behind it, what would you recommend as best practice to this? To return nothing, empty object... Something else?
Ah, sorry if I was unclear! I meant that we should always return a promise, regardless if a callback is provided or not. the promise type should probably void
to be more idiomatically correct, i.e it will always return a Promise<void>
.
:tada: This issue has been resolved in version 4.2.1 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
the return signature
Promise<{}> | undefined
is problematic due to[ts] Object is possibly 'undefined'.
. I get the fact that you want to accomodate both callbacks and promises, but one doesnt exclude the other, maybe I'm crazy and want both a callback and a promise returned? I can't see it do any harm to have a promise signature.