Fix bug with angular controller minsafe