add correct handling of query params in server sync