refactored contribute