1
0
mirror of https://github.com/processwire/processwire.git synced 2025-08-10 16:54:44 +02:00
This commit is contained in:
Ryan Cramer
2021-05-10 08:41:21 -04:00
parent 26f31ce81b
commit 422aeff7ac

View File

@@ -3357,7 +3357,7 @@ class ProcessTemplate extends Process implements ConfigurableModule {
if($removeTag && $template->hasTag($removeTag)) { if($removeTag && $template->hasTag($removeTag)) {
$template->removeTag($removeTag); $template->removeTag($removeTag);
} }
if(in_array($template->name, $tagTemplates)) { if(is_array($tagTemplates) && in_array($template->name, $tagTemplates)) {
// template should have the given tag // template should have the given tag
if($template->hasTag($saveTag)) continue; if($template->hasTag($saveTag)) continue;
$template->addTag($saveTag); $template->addTag($saveTag);