Refactored as object