easy promise function wrapping