updating rethinkdb code for new version