add a comment warning that note.project may be nil
This commit is contained in:
parent
273cd9c3c9
commit
e4789cdfdc
1 changed files with 4 additions and 0 deletions
|
@ -252,6 +252,10 @@ module NotificationRecipientService
|
|||
note.noteable
|
||||
end
|
||||
|
||||
# NOTE: may be nil, in the case of a PersonalSnippet
|
||||
#
|
||||
# (this is okay because NotificationRecipient is written
|
||||
# to handle nil projects)
|
||||
def project
|
||||
note.project
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue