If the incoming function returns a promise, return the promise. Otherwise, return a promise that resolves to the incoming function's return value.
If the incoming function returns a promise, return the promise. Otherwise, return a promise that resolves to the incoming function's return value.