diff options
author | VirtualTam <virtualtam@flibidi.net> | 2018-10-13 00:19:03 +0200 |
---|---|---|
committer | VirtualTam <virtualtam@flibidi.net> | 2018-12-02 22:39:16 +0100 |
commit | f211e417bf637b8a83988175c29ee072c69f7642 (patch) | |
tree | c33378b38ff1bd16e90934b5c60467a7e0395f53 /application/LinkUtils.php | |
parent | 04ec8fedd91642d4c0fc96258868086b8a51c899 (diff) | |
download | Shaarli-f211e417bf637b8a83988175c29ee072c69f7642.tar.gz Shaarli-f211e417bf637b8a83988175c29ee072c69f7642.tar.zst Shaarli-f211e417bf637b8a83988175c29ee072c69f7642.zip |
lint: apply phpcbf to application/
Signed-off-by: VirtualTam <virtualtam@flibidi.net>
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 | ||