Method: ActivityNotification.inherit_orm

Defined in:
lib/activity_notification.rb

.inherit_orm(model) ⇒ Object

Method used to choose which ORM to load when ActivityNotification::Notification class or ActivityNotification::Subscription class are being autoloaded



53
54
55
56
57
# File 'lib/activity_notification.rb', line 53

def self.inherit_orm(model)
  orm = ActivityNotification.config.orm
  require "activity_notification/orm/#{orm}"
  "ActivityNotification::ORM::#{orm.to_s.classify}::#{model}".constantize
end