Commit c882f0b3 authored by Dmitry Gruzd's avatar Dmitry Gruzd

Merge branch '344080-nomethoderror-undefined-method-name-for-nil-nilclass' into 'master'

Permit `MergeRequestDiffCommit#commit_author` to be nil

See merge request gitlab-org/gitlab!73258
parents 9a0d86b7 d1540ae9
...@@ -114,18 +114,18 @@ class MergeRequestDiffCommit < ApplicationRecord ...@@ -114,18 +114,18 @@ class MergeRequestDiffCommit < ApplicationRecord
end end
def author_name def author_name
commit_author.name commit_author&.name
end end
def author_email def author_email
commit_author.email commit_author&.email
end end
def committer_name def committer_name
committer.name committer&.name
end end
def committer_email def committer_email
committer.email committer&.email
end end
end end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment