parent
5828b51ba6
commit
23cf15a705
@ -1,5 +1,7 @@ |
||||
class Post < ApplicationRecord |
||||
belongs_to :profile |
||||
|
||||
validates :text, length: { maximum: 200 } |
||||
validates :text, presence: true, length: { maximum: 200 } |
||||
|
||||
validates :published_at, presence: true |
||||
end |
||||
|
Reference in new issue