summaryrefslogtreecommitdiff
path: root/plugins/af_comics/filters/af_comics_dilbert.php
diff options
context:
space:
mode:
authorwn_ <[email protected]>2023-12-30 15:38:41 +0000
committerwn_ <[email protected]>2023-12-30 15:39:17 +0000
commit90e7bf7cc385a64e3a91f30a6415a598ae0d0e99 (patch)
treecad5cb926791ff5284c7c20ffb5235181df02081 /plugins/af_comics/filters/af_comics_dilbert.php
parenta882eb13f7ab36f4bab26a290a8e5ab1c6f2fb34 (diff)
Update all UrlHelper::fetch() calls to use the associative array approach.
The other approach (passing in individual params) was marked as deprecated a few years ago.
Diffstat (limited to 'plugins/af_comics/filters/af_comics_dilbert.php')
-rw-r--r--plugins/af_comics/filters/af_comics_dilbert.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/af_comics/filters/af_comics_dilbert.php b/plugins/af_comics/filters/af_comics_dilbert.php
index a1c59b94c..bbd936621 100644
--- a/plugins/af_comics/filters/af_comics_dilbert.php
+++ b/plugins/af_comics/filters/af_comics_dilbert.php
@@ -9,10 +9,10 @@ class Af_Comics_Dilbert extends Af_ComicFilter {
function process(&$article) {
if (strpos($article["link"], "dilbert.com") !== false ||
strpos($article["link"], "/DilbertDailyStrip") !== false) {
-
- $res = UrlHelper::fetch($article["link"], false, false, false,
- false, false, 0,
- "Mozilla/5.0 (Windows NT 6.1; WOW64; rv:50.0) Gecko/20100101 Firefox/50.0");
+ $res = UrlHelper::fetch([
+ 'url' => $article['link'],
+ 'useragent' => 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:50.0) Gecko/20100101 Firefox/50.0',
+ ]);
if (!$res && UrlHelper::$fetch_last_error_content)
$res = UrlHelper::$fetch_last_error_content;