From afc7142250dc02654a53a7222abe88df964d58f4 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Sun, 28 Feb 2021 10:12:57 +0300 Subject: move all $fetch globals to UrlHelper --- plugins/af_readability/init.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'plugins/af_readability/init.php') diff --git a/plugins/af_readability/init.php b/plugins/af_readability/init.php index 172006d34..f8c7c125c 100755 --- a/plugins/af_readability/init.php +++ b/plugins/af_readability/init.php @@ -190,8 +190,6 @@ class Af_Readability extends Plugin { public function extract_content($url) { - global $fetch_effective_url; - $tmp = UrlHelper::fetch([ "url" => $url, "http_accept" => "text/*", @@ -224,13 +222,13 @@ class Af_Readability extends Plugin { foreach ($entries as $entry) { if ($entry->hasAttribute("href")) { $entry->setAttribute("href", - rewrite_relative_url($fetch_effective_url, $entry->getAttribute("href"))); + rewrite_relative_url(UrlHelper::$fetch_effective_url, $entry->getAttribute("href"))); } if ($entry->hasAttribute("src")) { $entry->setAttribute("src", - rewrite_relative_url($fetch_effective_url, $entry->getAttribute("src"))); + rewrite_relative_url(UrlHelper::$fetch_effective_url, $entry->getAttribute("src"))); } } -- cgit v1.2.3