- subject = I18n.t('notifier.note_comment_notification.subject_own', :commenter => comment.author_name) if @owner
- subject = I18n.t('notifier.note_comment_notification.subject_other', :commenter => comment.author_name) unless @owner
+ if comment.author
+ @commenter = comment.author.display_name
+ else
+ @commenter = I18n.t("notifier.note_comment_notification.anonymous")
+ end
+
+ if @owner
+ subject = I18n.t('notifier.note_comment_notification.subject_own', :commenter => @commenter)
+ else
+ subject = I18n.t('notifier.note_comment_notification.subject_other', :commenter => @commenter)
+ end