summaryrefslogtreecommitdiff
path: root/classes/urlhelper.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2021-11-14 20:53:30 +0300
committerAndrew Dolgov <[email protected]>2021-11-14 20:53:30 +0300
commit931a7533ce70f68b6890368220214e8d3f566180 (patch)
treed63cc35d83af29ab09c490976854c9c55b1310ff /classes/urlhelper.php
parent80291ffe0c3b43858cf9db3e5ffe5470259503ac (diff)
adjust some return types in urlhelper
Diffstat (limited to 'classes/urlhelper.php')
-rw-r--r--classes/urlhelper.php9
1 files changed, 4 insertions, 5 deletions
diff --git a/classes/urlhelper.php b/classes/urlhelper.php
index 351d66b8d..5d0d80a41 100644
--- a/classes/urlhelper.php
+++ b/classes/urlhelper.php
@@ -99,9 +99,8 @@ class UrlHelper {
}
}
- // extended filtering involves validation for safe ports and loopback
- /**
- * @return bool|string false if something went wrong, otherwise the URL string
+ /** extended filtering involves validation for safe ports and loopback
+ * @return false|string false if something went wrong, otherwise the URL string
*/
static function validate(string $url, bool $extended_filtering = false) {
@@ -166,7 +165,7 @@ class UrlHelper {
}
/**
- * @return bool|string
+ * @return false|string
*/
static function resolve_redirects(string $url, int $timeout, int $nest = 0) {
@@ -545,7 +544,7 @@ class UrlHelper {
}
/**
- * @return bool|string false if the provided URL didn't match expected patterns, otherwise the video ID string
+ * @return false|string false if the provided URL didn't match expected patterns, otherwise the video ID string
*/
public static function url_to_youtube_vid(string $url) {
$url = str_replace("youtube.com", "youtube-nocookie.com", $url);