some small bug fixes in proxy