Fixes #3 and resolving #7