Some minor refactoring
Some minor refactoring