about summary refs log tree commit diff
path: root/app/services/activitypub/fetch_remote_actor_service.rb
diff options
context:
space:
mode:
authorNick Schonning <nschonni@gmail.com>2023-02-21 19:57:56 -0500
committerGitHub <noreply@github.com>2023-02-22 09:57:56 +0900
commit4ff44be1348136fa602318cca343e716fea0e556 (patch)
tree07808238538eafc78b6401afd556331efb775a2d /app/services/activitypub/fetch_remote_actor_service.rb
parent8fd3fc404dd848253767252bbd76275e091832b1 (diff)
Autofix Rubocop Rails/Blank (#23765)
Diffstat (limited to 'app/services/activitypub/fetch_remote_actor_service.rb')
-rw-r--r--app/services/activitypub/fetch_remote_actor_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/activitypub/fetch_remote_actor_service.rb b/app/services/activitypub/fetch_remote_actor_service.rb
index ee0eaff08..c29570086 100644
--- a/app/services/activitypub/fetch_remote_actor_service.rb
+++ b/app/services/activitypub/fetch_remote_actor_service.rb
@@ -28,7 +28,7 @@ class ActivityPub::FetchRemoteActorService < BaseService
     raise Error, "Unsupported JSON-LD context for document #{uri}" unless supported_context?
     raise Error, "Unexpected object type for actor #{uri} (expected any of: #{SUPPORTED_TYPES})" unless expected_type?
     raise Error, "Actor #{uri} has moved to #{@json['movedTo']}" if break_on_redirect && @json['movedTo'].present?
-    raise Error, "Actor #{uri} has no 'preferredUsername', which is a requirement for Mastodon compatibility" unless @json['preferredUsername'].present?
+    raise Error, "Actor #{uri} has no 'preferredUsername', which is a requirement for Mastodon compatibility" if @json['preferredUsername'].blank?
 
     @uri      = @json['id']
     @username = @json['preferredUsername']