aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJan-Hendrik Willms <tleilax+studip@gmail.com>2025-07-18 10:40:57 +0200
committerJan-Hendrik Willms <tleilax+studip@gmail.com>2025-07-18 10:40:57 +0200
commit2a3e3ecc72417a7bffbbc572d69282fae571668b (patch)
treef057c12fe94690fd6f92b46b11a4b515a6940b76 /lib
parentd5c35cdc9eeb40dd012298158962ce596018a2a4 (diff)
prevent php warnings, fixes #5723
Closes #5723 Merge request studip/studip!4368
Diffstat (limited to 'lib')
-rw-r--r--lib/functions.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/functions.php b/lib/functions.php
index 0849162..3198cb1 100644
--- a/lib/functions.php
+++ b/lib/functions.php
@@ -819,7 +819,7 @@ function is_internal_url($url)
return mb_strpos($url, $GLOBALS['ABSOLUTE_URI_STUDIP']) === 0;
}
- if ($url[0] === '/') {
+ if (str_starts_with($url, '/')) {
return mb_strpos($url, $GLOBALS['CANONICAL_RELATIVE_PATH_STUDIP']) === 0;
}