lib/jera_push/models/device.rb in jera_push-1.1.0 vs lib/jera_push/models/device.rb in jera_push-1.1.1

- old
+ new

@@ -5,11 +5,12 @@ DEFAULT_TOPIC = 'general' self.table_name = "jera_push_devices" - has_many :messages, through: :message_devices, table_name: "jera_push_messages" has_many :message_devices, table_name: "jera_push_message_devices" + has_many :messages, through: :message_devices, table_name: "jera_push_messages" + belongs_to :pushable, polymorphic: true validates :token, :platform, presence: true validates :token, uniqueness: { scope: :platform }