more refactoring
weiter an #14
finally fixes #14