diff options
Diffstat (limited to 'application/LinkUtils.php')
-rw-r--r-- | application/LinkUtils.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/application/LinkUtils.php b/application/LinkUtils.php index 4df5c0ca..d56e019f 100644 --- a/application/LinkUtils.php +++ b/application/LinkUtils.php | |||
@@ -23,7 +23,7 @@ function get_curl_download_callback(&$charset, &$title, $curlGetInfo = 'curl_get | |||
23 | * | 23 | * |
24 | * @return int|bool length of $data or false if we need to stop the download | 24 | * @return int|bool length of $data or false if we need to stop the download |
25 | */ | 25 | */ |
26 | return function(&$ch, $data) use ($curlGetInfo, &$charset, &$title, &$isRedirected) { | 26 | return function (&$ch, $data) use ($curlGetInfo, &$charset, &$title, &$isRedirected) { |
27 | $responseCode = $curlGetInfo($ch, CURLINFO_RESPONSE_CODE); | 27 | $responseCode = $curlGetInfo($ch, CURLINFO_RESPONSE_CODE); |
28 | if (!empty($responseCode) && in_array($responseCode, [301, 302])) { | 28 | if (!empty($responseCode) && in_array($responseCode, [301, 302])) { |
29 | $isRedirected = true; | 29 | $isRedirected = true; |
@@ -201,7 +201,8 @@ function space2nbsp($text) | |||
201 | 201 | ||
202 | * @return string formatted description. | 202 | * @return string formatted description. |
203 | */ | 203 | */ |
204 | function format_description($description, $redirector = '', $urlEncode = true, $indexUrl = '') { | 204 | function format_description($description, $redirector = '', $urlEncode = true, $indexUrl = '') |
205 | { | ||
205 | return nl2br(space2nbsp(hashtag_autolink(text2clickable($description, $redirector, $urlEncode), $indexUrl))); | 206 | return nl2br(space2nbsp(hashtag_autolink(text2clickable($description, $redirector, $urlEncode), $indexUrl))); |
206 | } | 207 | } |
207 | 208 | ||