Fall back to Report if no subclass is detectable

pull/6827/head
Konstantin Haase 14 years ago
parent 01f97b2580
commit 1ef60898b4
  1. 2
      app/models/report/query_utils.rb

@ -8,7 +8,7 @@ module Report::QueryUtils
# @return [Class] subclass # @return [Class] subclass
def engine def engine
return self.class.engine unless is_a? Module return self.class.engine unless is_a? Module
Object.const_get name[/^[^:]+/] Object.const_get(name[/^[^:]+/] || :Report)
end end
## ##

Loading…
Cancel
Save