fixes to the proxy code