Inherit models from ApplicationRecord instead of ActiveRecord::Base.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
class ModAction < ActiveRecord::Base
|
||||
class ModAction < ApplicationRecord
|
||||
belongs_to :creator, :class_name => "User"
|
||||
before_validation :initialize_creator, :on => :create
|
||||
validates_presence_of :creator_id
|
||||
|
||||
Reference in New Issue
Block a user