fixing IUGATEWAY-249 and IUGATEWAY-250