Fixed remaining two issues
Merge pull request #17 from dingledow/remaining-issues

Fixed remaining two issues