Fix exception when creating user outside of department