# This module provides an in-place wrapper for ActiveRecord::Relation. # # So instead of doing this: # rel = SomeModel.where( … ) # rel = rel.joins(…).where(…) if x # rel = rel.select(…) unless y # rel = rel.some_scope( params ) # rel = rel.merge( another_rel ) # rel.all # # you can do this: # rel = SomeModel.where( … ).in_place # rel.joins(…).where(…) if x # rel.select(…) unless y # rel.some_scope( params ) # rel.merge( another_rel ) # rel.all # # All ActiveRecord::Relation methods are either wrapped and return wrapper # itself or are passed directly to underlying relation object. In rare case you # might want to access this relation object directly, use #relation method