fixes #11 fixes #12 fixes #13 fixes #14