nasty bugfix (closes #13)