Style/ParenthesesAroundCondition:
Exclude:
- 'app/models/repository/subversion.rb'
- - 'app/models/time_entry.rb'
- 'app/models/wiki_page.rb'
- 'lib/diff.rb'
- 'lib/redmine/helpers/gantt.rb'
end
end
errors.add :project_id, :invalid if project.nil?
- errors.add :user_id, :invalid if (user_id != author_id && !self.assignable_users.map(&:id).include?(user_id))
+ errors.add :user_id, :invalid if user_id != author_id && !self.assignable_users.map(&:id).include?(user_id)
errors.add :issue_id, :invalid if (issue_id && !issue) || (issue && project!=issue.project) || @invalid_issue_id
errors.add :activity_id, :inclusion if activity_id_changed? && project && !project.activities.include?(activity)
if spent_on_changed? && user
- errors.add :base, I18n.t(:error_spent_on_future_date) if (!Setting.timelog_accept_future_dates? && (spent_on > user.today))
+ errors.add :base, I18n.t(:error_spent_on_future_date) if !Setting.timelog_accept_future_dates? && (spent_on > user.today)
end
end