Module: RoarExtensions::Presenter::ConditionalEmbeds
- Defined in:
- lib/roar_extensions/presenter.rb
Instance Method Summary collapse
Instance Method Details
#embed_property?(binding) ⇒ Boolean
15 16 17 |
# File 'lib/roar_extensions/presenter.rb', line 15 def (binding) (@embedded & [binding.name.to_sym, binding.from.to_sym]).present? end |
#skip_property?(bin, options) ⇒ Boolean
7 8 9 10 11 12 13 |
# File 'lib/roar_extensions/presenter.rb', line 7 def skip_property?(bin, ) if bin.[:embedded] super || !(bin) else super end end |