Skip to content
This repository was archived by the owner on Jul 24, 2023. It is now read-only.

Commit 6bcd3d0

Browse files
committed
Update admin/mkassoc to enable to work
1 parent 5dd1130 commit 6bcd3d0

1 file changed

Lines changed: 8 additions & 3 deletions

File tree

admin/mkassoc

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
11
#!/usr/bin/env ruby
22

33
require "openid/consumer/associationmanager"
4-
require "openid/store/memstore"
4+
require "openid/store/memory"
55

6-
store = OpenID::MemoryStore.new
6+
store = OpenID::Store::Memory.new
77
ARGV.each do |server_url|
8-
mgr = OpenID::Consumer::AssociationManager.new(store, URI.parse(server_url))
8+
unless URI::regexp =~ server_url
9+
puts "`#{server_url}` will be skipped for invalid URI format."
10+
next
11+
end
12+
13+
mgr = OpenID::Consumer::AssociationManager.new(store, server_url)
914
puts '=' * 50
1015
puts "Server: #{server_url}"
1116
puts mgr.get_association.serialize

0 commit comments

Comments
 (0)