fix code style
minor refactoring
minor improvement