diff --git a/.github/lib/discussions.rb b/.github/lib/discussions.rb index d20341aaf..5f9c607b2 100644 --- a/.github/lib/discussions.rb +++ b/.github/lib/discussions.rb @@ -443,7 +443,7 @@ def find_most_recent_incident_comment_id(actor_login:) return nil if comments.empty? - filtered_comments = comments.keep_if { |comment| comment["author"]["login"] == actor_login } + filtered_comments = comments.keep_if { |comment| comment["author"] && comment["author"]["login"] == actor_login } &.sort_by { |comment| comment["createdAt"] } .reverse