Fixes #1, Fixes #5, Fixes #6