diff options
author | Andreas Brandl <abrandl@gitlab.com> | 2018-02-04 22:46:14 +0300 |
---|---|---|
committer | Andreas Brandl <abrandl@gitlab.com> | 2018-02-05 18:16:57 +0300 |
commit | 24a11c957a34d2f22c0276fa8dcc3e2c23d1f164 (patch) | |
tree | de56172ee3b0627f5bebb74a8d08ea13c3dc3aa7 /app | |
parent | d07addbf6e3841ae31a7e62ecbb29523f4d8c859 (diff) |
Set todos#author_id to NOT NULL.
Diffstat (limited to 'app')
-rw-r--r-- | app/models/todo.rb | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/app/models/todo.rb b/app/models/todo.rb index 7af54b2beb2..bb5965e20eb 100644 --- a/app/models/todo.rb +++ b/app/models/todo.rb @@ -28,6 +28,7 @@ class Todo < ActiveRecord::Base delegate :name, :email, to: :author, prefix: true, allow_nil: true validates :action, :project, :target_type, :user, presence: true + validates :author, presence: true validates :target_id, presence: true, unless: :for_commit? validates :commit_id, presence: true, if: :for_commit? |