Module: Mixpal::Integration
- Extended by:
- ActiveSupport::Concern
- Defined in:
- lib/mixpal/integration.rb
Instance Method Summary collapse
Instance Method Details
#mixpanel ⇒ Object
22 23 24 25 26 27 28 29 30 |
# File 'lib/mixpal/integration.rb', line 22 def mixpanel @mixpanel ||= begin identity = if (data = self.class.mixpanel_identity_data) send(data[:object_method]).try(data[:attribute_method]) end Mixpal::Tracker.new(identity: identity).tap { |t| t.restore!(session) } end end |