Fix bugs with HMDA loading

Solves https://sprint.ly/product/8048/#!/item/180