diff --git a/lib/phlex/rails/sgml.rb b/lib/phlex/rails/sgml.rb index 0e080bd4..d8b75299 100644 --- a/lib/phlex/rails/sgml.rb +++ b/lib/phlex/rails/sgml.rb @@ -81,11 +81,10 @@ def __text__(content) end end - # @api private def await(task) - if task.is_a?(ActiveRecord::Relation) + case task + when ActiveRecord::Relation flush unless task.loaded? - task else super