refactored definitions