Module: Messenger::Components::Element
- Included in:
- Elements::Address, Elements::Adjustment, Elements::Bubble, Elements::Item, Elements::Order, Elements::QuickReply, Elements::Summary, Templates::QuickReplies
- Defined in:
- lib/messenger/components/element.rb
Instance Method Summary collapse
Instance Method Details
#build ⇒ Object
4 5 6 |
# File 'lib/messenger/components/element.rb', line 4 def build instance_values.delete_if { |_attribute, value| value.nil? } end |
#build_elements(elements) ⇒ Object
8 9 10 |
# File 'lib/messenger/components/element.rb', line 8 def build_elements(elements) elements.map { |element| element.build } if elements.present? end |