changes to comply to the new version of the API