Tag: move-method

Daily Refactor #2: Move Method in the BulkTimeEntriesController – saving a new TimeEntry

The Refactoring Following up to yesterday’s refactoring, today I kept refactoring the Bulk Time Entry plugin’s controller. The save_time_entry_from_params method I extracted yesterday only uses the TimeEntry class, so it would be perfect to move the method to the TimeEntry class. Since the TimeEntry class is defined by Redmine, I had to monkey-patch that class. …

Read more