minor refactore