How to refactor this redundant 'await' on a non-promise :- From SonarCloud

Viewed 21

I am getting this warning from SonarQube to refactor.My Codes are

if (isRestockNotAccount) { res = await createRestockInventoryHospital({ ledger, roleCid, inventorydata: invdata, }); } else { res = await createAccountInventoryHospital({ ledger, roleCid, inventorydata: invdata, });

0 Answers
Related