added adapt as a parameter