small fix
minor refactoring