makes necessary changes