Modifies the trajectory update such that the goal of the updated trajectory is within the task manifold