summaryrefslogtreecommitdiff
path: root/plugins/af_zz_imgproxy
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/af_zz_imgproxy')
-rw-r--r--plugins/af_zz_imgproxy/init.php9
1 files changed, 9 insertions, 0 deletions
diff --git a/plugins/af_zz_imgproxy/init.php b/plugins/af_zz_imgproxy/init.php
index 6d7954c3c..923f81734 100644
--- a/plugins/af_zz_imgproxy/init.php
+++ b/plugins/af_zz_imgproxy/init.php
@@ -18,10 +18,19 @@ class Af_Zz_ImgProxy extends Plugin {
$host->add_hook($host::HOOK_RENDER_ARTICLE, $this);
$host->add_hook($host::HOOK_RENDER_ARTICLE_CDM, $this);
$host->add_hook($host::HOOK_RENDER_ARTICLE_API, $this);
+ $host->add_hook($host::HOOK_ENCLOSURE_ENTRY, $this);
$host->add_hook($host::HOOK_PREFS_TAB, $this);
}
+ function hook_enclosure_entry($enc) {
+ $proxy_all = $this->host->get($this, "proxy_all");
+
+ $enc["url"] = $this->rewrite_url_if_needed($enc["url"], $proxy_all);
+
+ return $enc;
+ }
+
function hook_render_article($article) {
return $this->hook_render_article_cdm($article);
}