make it work on latest sync gateway version