From 52e11ea8c12456f8ad7be8373a36792f0243883c Mon Sep 17 00:00:00 2001 From: Christophe Maudoux Date: Thu, 26 Jul 2018 20:52:16 +0200 Subject: [PATCH] Avoid debug warning --- _example/test/oauth2.pl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/_example/test/oauth2.pl b/_example/test/oauth2.pl index e218f5949..9587633aa 100755 --- a/_example/test/oauth2.pl +++ b/_example/test/oauth2.pl @@ -20,7 +20,8 @@ use Digest::SHA #============================================================================== my $host = $ENV{HTTP_HOST}; my ( $domain, $port ) = ( $host =~ /\w+\.([^:]+)(:\d+)?/ ); -my $protocol = ( $ENV{HTTPS} =~ /^on$/i ) ? "https" : "http"; +my $protocol = ( $ENV{HTTPS} =~ /^on$/i ) ? "https" : "http"; +$port ||= ""; my $portal_url = "$protocol://auth.$domain$port"; my $client_id = "lemonldap"; my $client_secret = "secret";