DEV Community

Discussion on: Advanced Node.js Topics: Caching.

Collapse
 
revenity profile image
Revenity
(async function () {

await client.connect()

})()
Enter fullscreen mode Exit fullscreen mode

->

client.connect();
Enter fullscreen mode Exit fullscreen mode
Collapse
 
osam1010 profile image
Osama

Thanks for correcting me, in one article before i thought i need to wrap the connect function with async IIFE, i tried it now without the IIFE and it works perfect!
Thanks.