Code cleanup. Added comments.

This commit is contained in:
watsonb8
2019-06-17 15:59:15 -04:00
parent 5040435760
commit 8bb65b5b3c
7 changed files with 86 additions and 32 deletions

View File

@ -1,5 +1,8 @@
/**
* Helper function to convert callbacks into promises
* @param func
*/
export default function callbackify(func: (...args: any[]) => Promise<any>): Function {
return (...args: any[]) => {
const onlyArgs: any[] = [];