diff options
author | Jeremy Benoist <jeremy.benoist@gmail.com> | 2017-06-01 22:58:38 +0200 |
---|---|---|
committer | Jeremy Benoist <jeremy.benoist@gmail.com> | 2017-06-01 22:58:38 +0200 |
commit | 9bf7752f73ebfbfea0adbdb0d562a3cfa85039f3 (patch) | |
tree | 927d63db163eaa57bfeb16500f1c826601214b47 /src/Wallabag | |
parent | fcad69a427de7ce4f65cbf53bcf778e561959807 (diff) | |
download | wallabag-9bf7752f73ebfbfea0adbdb0d562a3cfa85039f3.tar.gz wallabag-9bf7752f73ebfbfea0adbdb0d562a3cfa85039f3.tar.zst wallabag-9bf7752f73ebfbfea0adbdb0d562a3cfa85039f3.zip |
CS
Diffstat (limited to 'src/Wallabag')
-rw-r--r-- | src/Wallabag/CoreBundle/Helper/DownloadImages.php | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/Wallabag/CoreBundle/Helper/DownloadImages.php b/src/Wallabag/CoreBundle/Helper/DownloadImages.php index f7c26a38..54e23a05 100644 --- a/src/Wallabag/CoreBundle/Helper/DownloadImages.php +++ b/src/Wallabag/CoreBundle/Helper/DownloadImages.php | |||
@@ -54,7 +54,7 @@ class DownloadImages | |||
54 | $crawler = new Crawler($html); | 54 | $crawler = new Crawler($html); |
55 | $result = $crawler | 55 | $result = $crawler |
56 | ->filterXpath('//img') | 56 | ->filterXpath('//img') |
57 | ->extract(array('src')); | 57 | ->extract(['src']); |
58 | 58 | ||
59 | $relativePath = $this->getRelativePath($entryId); | 59 | $relativePath = $this->getRelativePath($entryId); |
60 | 60 | ||
@@ -66,8 +66,7 @@ class DownloadImages | |||
66 | continue; | 66 | continue; |
67 | } | 67 | } |
68 | 68 | ||
69 | // if image contains "&"" and we can't find it in the html | 69 | // if image contains "&" and we can't find it in the html it might be because it's encoded as & |
70 | // it might be because it's encoded as & | ||
71 | if (false !== stripos($image, '&') && false === stripos($html, $image)) { | 70 | if (false !== stripos($image, '&') && false === stripos($html, $image)) { |
72 | $image = str_replace('&', '&', $image); | 71 | $image = str_replace('&', '&', $image); |
73 | } | 72 | } |