Fixes #1 and closes #2