Bug/unitname

Fixes #728