From 0daa5daf0c3121a652dbbe98766fbe5e3359a613 Mon Sep 17 00:00:00 2001 From: Yuji Yaginuma Date: Thu, 6 Jun 2024 15:22:48 +0900 Subject: [PATCH] Don't use obsoleted `URI.regexp` `URI.regexp` is obsoleted since Ruby 2.2. ``` $ ruby -w -r "uri" -e "URI::regexp" -e:1: warning: URI.regexp is obsolete ``` --- lib/openid_connect/client/registrar.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/openid_connect/client/registrar.rb b/lib/openid_connect/client/registrar.rb index 3969572..1cf1bd6 100644 --- a/lib/openid_connect/client/registrar.rb +++ b/lib/openid_connect/client/registrar.rb @@ -118,7 +118,7 @@ def sector_identifier_required? def valid_uri?(uri, schemes = ['http', 'https']) # NOTE: specify nil for schemes to allow any schemes - URI::regexp(schemes).match(uri).present? + URI::DEFAULT_PARSER.make_regexp(schemes).match(uri).present? end def validate_contacts