summaryrefslogtreecommitdiffstats
path: root/app/models/project.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/project.rb')
-rw-r--r--app/models/project.rb24
1 files changed, 10 insertions, 14 deletions
diff --git a/app/models/project.rb b/app/models/project.rb
index d68958e27..805e29414 100644
--- a/app/models/project.rb
+++ b/app/models/project.rb
@@ -449,24 +449,20 @@ class Project < ActiveRecord::Base
# The earliest start date of a project, based on it's issues and versions
def start_date
- if module_enabled?(:issue_tracking)
- [
- issues.minimum('start_date'),
- shared_versions.collect(&:effective_date),
- shared_versions.collect {|v| v.fixed_issues.minimum('start_date')}
- ].flatten.compact.min
- end
+ [
+ issues.minimum('start_date'),
+ shared_versions.collect(&:effective_date),
+ shared_versions.collect {|v| v.fixed_issues.minimum('start_date')}
+ ].flatten.compact.min
end
# The latest due date of an issue or version
def due_date
- if module_enabled?(:issue_tracking)
- [
- issues.maximum('due_date'),
- shared_versions.collect(&:effective_date),
- shared_versions.collect {|v| v.fixed_issues.maximum('due_date')}
- ].flatten.compact.max
- end
+ [
+ issues.maximum('due_date'),
+ shared_versions.collect(&:effective_date),
+ shared_versions.collect {|v| v.fixed_issues.maximum('due_date')}
+ ].flatten.compact.max
end
def overdue?