bumped version and did a minor refactoring