From 984dd1fdb062427bc2599abad49d1027182824d3 Mon Sep 17 00:00:00 2001
From: Jaime Perez Crespo <jaime.perez@uninett.no>
Date: Tue, 7 Jun 2016 15:27:57 +0200
Subject: [PATCH] Minor change to enhance code clarity.

---
 lib/SimpleSAML/Utils/HTTP.php | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/lib/SimpleSAML/Utils/HTTP.php b/lib/SimpleSAML/Utils/HTTP.php
index d802370dc..b90a793c8 100644
--- a/lib/SimpleSAML/Utils/HTTP.php
+++ b/lib/SimpleSAML/Utils/HTTP.php
@@ -966,14 +966,13 @@ class HTTP
             return $baseScheme.$url;
         }
 
-        $firstChar = substr($url, 0, 1);
-        if ($firstChar === '/') {
+        if ($url[0] === '/') {
             return $baseHost.$url;
         }
-        if ($firstChar === '?') {
+        if ($url[0] === '?') {
             return $basePath.$url;
         }
-        if ($firstChar === '#') {
+        if ($url[0] === '#') {
             return $baseQuery.$url;
         }
 
-- 
GitLab