re #48 - now uses same technique as on dev portal