FIX: Do not show post notices for bots.

FIX: Do not show post notices for bots.

diff --git a/app/serializers/post_serializer.rb b/app/serializers/post_serializer.rb
index 9df5e31..f7a683b 100644
--- a/app/serializers/post_serializer.rb
+++ b/app/serializers/post_serializer.rb
@@ -371,7 +371,7 @@ class PostSerializer < BasicPostSerializer
 
   def include_post_notice_type?
     return false if !scope.user || !scope.user.id || scope.user.id == object.user_id ||
-                    !object.user || object.user.anonymous? ||
+                    !object.user || object.user.anonymous? || object.user.bot?
                     !scope.user.has_trust_level?(SiteSetting.min_post_notice_tl)
 
     post_notice_type.present?

GitHub sha: eed1c9e0

1 Like

DEV: Fix build.