Remove (long) obsolete edge case
This commit is contained in:
parent
fcea11f0e5
commit
3e9a08a266
@ -23,12 +23,8 @@ class RemoteStorageAuthorization < ApplicationRecord
|
||||
after_destroy :remove_token_expiry_job
|
||||
|
||||
def url
|
||||
if self.redirect_uri
|
||||
uri = URI.parse self.redirect_uri
|
||||
"#{uri.scheme}://#{client_id}"
|
||||
else
|
||||
"http://#{client_id}"
|
||||
end
|
||||
end
|
||||
|
||||
def delete_token_from_redis
|
||||
|
@ -1,8 +1,8 @@
|
||||
FactoryBot.define do
|
||||
factory :remote_storage_authorization do
|
||||
permissions { ["documents:rw"] }
|
||||
client_id { "some-fancy-app" }
|
||||
redirect_uri { "https://example.com/some-fancy-app" }
|
||||
client_id { "app.example.com" }
|
||||
redirect_uri { "https://app.example.com" }
|
||||
app_name { "Fancy App" }
|
||||
expire_at { 1.month.from_now }
|
||||
web_app
|
||||
|
Loading…
x
Reference in New Issue
Block a user