Skip to content

Commit

Permalink
set up message validations
Browse files Browse the repository at this point in the history
  • Loading branch information
sjfox26 committed Apr 4, 2018
1 parent 5c2b3df commit a27cead
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
19 changes: 8 additions & 11 deletions .idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions app/models/message.rb
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
class Message
include ActiveModel::Model
attr_accessor :name, :phone_number, :body
validates :name, :phone_number, :body, presence: true
end

0 comments on commit a27cead

Please sign in to comment.