Refactored article logic into class