adjusting function wrapping