starting to rework structure according to #31 fixes #39