about summary refs log tree commit diff
path: root/app/models
diff options
context:
space:
mode:
authorThibaut Girka <thib@sitedethib.com>2020-05-13 22:11:49 +0200
committerThibaut Girka <thib@sitedethib.com>2020-05-13 22:11:49 +0200
commit3baacf6993581ba91e3e3ae0071b25a645d71115 (patch)
treeec1dbae77aef8bd43e6f5cfef41dfbc72f133ca3 /app/models
parent559214c33fc0c5b5ee621eb2719fa1a15ac9da95 (diff)
parent92f85bea528c5eca97a2f075c53f7dcafdf5cb41 (diff)
Merge branch 'master' into glitch-soc/merge-upstream
Diffstat (limited to 'app/models')
-rw-r--r--app/models/web/push_subscription.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/app/models/web/push_subscription.rb b/app/models/web/push_subscription.rb
index c5dbb58ba..c407a7789 100644
--- a/app/models/web/push_subscription.rb
+++ b/app/models/web/push_subscription.rb
@@ -94,11 +94,11 @@ class Web::PushSubscription < ApplicationRecord
 
   def find_or_create_access_token
     Doorkeeper::AccessToken.find_or_create_for(
-      Doorkeeper::Application.find_by(superapp: true),
-      session_activation.user_id,
-      Doorkeeper::OAuth::Scopes.from_string('read write follow push'),
-      Doorkeeper.configuration.access_token_expires_in,
-      Doorkeeper.configuration.refresh_token_enabled?
+      application: Doorkeeper::Application.find_by(superapp: true),
+      resource_owner: session_activation.user_id,
+      scopes: Doorkeeper::OAuth::Scopes.from_string('read write follow push'),
+      expires_in: Doorkeeper.configuration.access_token_expires_in,
+      use_refresh_token: Doorkeeper.configuration.refresh_token_enabled?
     )
   end
 end