Fixed Issue #23, refactor, renamed variables
Merge pull request #24 from PtrMan/master

Fixed Issue #23, refactor, renamed variables