fix bugs
Merge remote-tracking branch 'upstream/master'
fix inconsistency
Merge pull request #21 from Danghor/master

Fix Bugs and Inconsistencies