v1.2.2: Fixed #7 and Fixed #8

Fixed issues #7 and #8.