done with new way of implementing the function execution