about summary refs log tree commit diff
path: root/app/services/keys
diff options
context:
space:
mode:
Diffstat (limited to 'app/services/keys')
-rw-r--r--app/services/keys/claim_service.rb8
-rw-r--r--app/services/keys/query_service.rb8
2 files changed, 8 insertions, 8 deletions
diff --git a/app/services/keys/claim_service.rb b/app/services/keys/claim_service.rb
index ae9e24a24..ebce9cce7 100644
--- a/app/services/keys/claim_service.rb
+++ b/app/services/keys/claim_service.rb
@@ -9,10 +9,10 @@ class Keys::ClaimService < BaseService
 
     def initialize(account, device_id, key_attributes = {})
       super(
-        account:   account,
+        account: account,
         device_id: device_id,
-        key_id:    key_attributes[:key_id],
-        key:       key_attributes[:key],
+        key_id: key_attributes[:key_id],
+        key: key_attributes[:key],
         signature: key_attributes[:signature],
       )
     end
@@ -58,7 +58,7 @@ class Keys::ClaimService < BaseService
 
     @result = Result.new(@target_account, @device_id, key_id: json['id'], key: json['publicKeyBase64'], signature: json.dig('signature', 'signatureValue'))
   rescue HTTP::Error, OpenSSL::SSL::SSLError, Mastodon::Error => e
-    Rails.logger.debug "Claiming one-time key for #{@target_account.acct}:#{@device_id} failed: #{e}"
+    Rails.logger.debug { "Claiming one-time key for #{@target_account.acct}:#{@device_id} failed: #{e}" }
     nil
   end
 
diff --git a/app/services/keys/query_service.rb b/app/services/keys/query_service.rb
index ac3388bdc..14c9d9205 100644
--- a/app/services/keys/query_service.rb
+++ b/app/services/keys/query_service.rb
@@ -23,9 +23,9 @@ class Keys::QueryService < BaseService
 
     def initialize(attributes = {})
       super(
-        device_id:       attributes[:device_id],
-        name:            attributes[:name],
-        identity_key:    attributes[:identity_key],
+        device_id: attributes[:device_id],
+        name: attributes[:name],
+        identity_key: attributes[:identity_key],
         fingerprint_key: attributes[:fingerprint_key],
       )
       @claim_url = attributes[:claim_url]
@@ -73,7 +73,7 @@ class Keys::QueryService < BaseService
       Device.new(device_id: device['id'], name: device['name'], identity_key: device.dig('identityKey', 'publicKeyBase64'), fingerprint_key: device.dig('fingerprintKey', 'publicKeyBase64'), claim_url: device['claim'])
     end
   rescue HTTP::Error, OpenSSL::SSL::SSLError, Mastodon::Error => e
-    Rails.logger.debug "Querying devices for #{@account.acct} failed: #{e}"
+    Rails.logger.debug { "Querying devices for #{@account.acct} failed: #{e}" }
     nil
   end
 end