lambda-wrapper
lambda-wrapper copied to clipboard
fix: Simplify promises and callbacks
Replaces some of the harder-to-understand use of callback-style async and new Promise with simpler async-await. As a bonus, we can remove the async dependency!
This also fixes a bug in SQSService#checkStatus, where a failed listQueues call can result in a TypeError if the data parameter of the callback is undefined or null. Previously the unit tests ignored this by passing an empty object (see the deleted createCallbackMock function).
No specific Jira ticket, but removal of async completes ENG-3212