Small commands refactoring