await-to-js
await-to-js copied to clipboard
refactor: remove response undefined type
Hi!
This pull request follows from this issue https://github.com/scopsy/await-to-js/issues/14
const [error, response] = await to<ResponseDTO>(myApiCall());
// expect response as ResponseDTO, receive ResponseDTO | undefined