Fixes to #7 and #8, upgrading version to 2.2.2