Fixes #9
Fixes #12
Fixes #13