Tidy up collection handling in Proxy::getValue()