updated to be compatible with latest version of rethinkdb 1.11