summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--CHANGELOG.txt1
-rw-r--r--includes/context.inc3
2 files changed, 4 insertions, 0 deletions
diff --git a/CHANGELOG.txt b/CHANGELOG.txt
index 7a45e10..816f529 100644
--- a/CHANGELOG.txt
+++ b/CHANGELOG.txt
@@ -31,6 +31,7 @@ Add a couple of support functions for ctools_set_page_token that are meant to be
#424548: Add a warning about overridng pager settings with Views AJAX.
#555802: Add an administrative title to custom content panes to make them easier to manage.
#556870: Node edit settings form context autocomplete was not working correctly.
+#491884 by ayalon: Provide blank substitutions for optional contexts that do not appear.
ctools 6.x-1.0
==============
diff --git a/includes/context.inc b/includes/context.inc
index c1ff548..ac450ec 100644
--- a/includes/context.inc
+++ b/includes/context.inc
@@ -613,6 +613,9 @@ function ctools_context_keyword_substitute($string, $keywords, $contexts) {
if (isset($context_keywords[$context])) {
$keywords['%' . $keyword] = ctools_context_convert_context($context_keywords[$context], $converter);
}
+ else {
+ $keywords['%' . $keyword] = '';
+ }
}
else {
if (isset($context_keywords[$keyword])) {