p-whilst

While a condition returns true, calls a function repeatedly, and then resolves the promise

p-do-whilst

Calls a function repeatedly while a condition returns true and then resolves the promise