fixes #3, #2