From 6f08073524cd0596d20dc755c5f9e32d91717d95 Mon Sep 17 00:00:00 2001
From: Matthew Exon
Date: Sun, 13 Oct 2019 11:27:19 +0200
Subject: [PATCH] remove help section if images not allowed
---
retriever/retriever.php | 1 +
retriever/templates/help.tpl | 2 ++
2 files changed, 3 insertions(+)
diff --git a/retriever/retriever.php b/retriever/retriever.php
index 33f9a40e0..6b71c36e2 100644
--- a/retriever/retriever.php
+++ b/retriever/retriever.php
@@ -831,6 +831,7 @@ function retriever_content($a) {
$template = Renderer::getMarkupTemplate('/help.tpl', 'addon/retriever/');
$a->page['content'] .= Renderer::replaceMacros($template, array(
'$config' => $a->getBaseUrl . '/settings/addon',
+ '$allow_images' => Config::get('retriever', 'allow_images'),
'$feeds' => $feeds));
return;
}
diff --git a/retriever/templates/help.tpl b/retriever/templates/help.tpl
index b96ec63c3..7298c1305 100644
--- a/retriever/templates/help.tpl
+++ b/retriever/templates/help.tpl
@@ -131,6 +131,7 @@ fails, the plugin will keep trying at progressively longer intervals
for up to a month, in case the website is temporarily overloaded or
the network is down.
+{{if $allow_images}}
Retrieving Images
Retriever can also optionally download images and store them in the
@@ -140,6 +141,7 @@ an RSS feed or not. Go to the "Settings" page and
click "Plugin settings". Then check the "All
Photos" box in the "Retriever Settings" section and click "Submit".
+{{/if}}
Configure Feeds:
{{foreach $feeds as $feed}}