Skip to content

Commit 9f7335b

Browse files
committed
Use ApplicationRecord as base class for SubscriptionTemplate if available
1 parent 67299d3 commit 9f7335b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/models/subscription_template.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
class SubscriptionTemplate < ActiveRecord::Base
1+
class SubscriptionTemplate < (defined?(ApplicationRecord) == 'constant' ? ApplicationRecord : ActiveRecord::Base)
22
self.table_name = "fiware_subscription_templates"
33

44
after_initialize :set_default_alteration_types, if: :new_record?

0 commit comments

Comments
 (0)