Ensure context is always set
authorEileen McNaughton <emcnaughton@wikimedia.org>
Wed, 10 Nov 2021 21:52:40 +0000 (10:52 +1300)
committerEileen McNaughton <emcnaughton@wikimedia.org>
Fri, 12 Nov 2021 07:27:25 +0000 (20:27 +1300)
CRM/Core/Page.php
templates/CRM/Contact/Page/View/Summary.tpl

index 7404125fc8fae5d8fa08758a8b04e4890d1716e3..ecdf2450f13c7bc07785e69550018ad98f96af46 100644 (file)
@@ -118,6 +118,9 @@ class CRM_Core_Page {
     'infoTitle',
     'infoType',
     'infoOptions',
+    // required for Summary.tpl (contact summary) but seems
+    // likely to be used more broadly to warrant inclusion here.
+    'context',
   ];
 
   /**
index fd7b3bc32e1f8f92d93217569f654d185e6aa371..f6eb81a871cca0f3d254e4abede61f8afa8e5b65 100644 (file)
@@ -26,7 +26,7 @@
         {if !empty($searchKey)}
           {assign var='urlParams' value=$urlParams|cat:"&key=$searchKey"}
         {/if}
-        {if !empty($context)}
+        {if $context}
           {assign var='urlParams' value=$urlParams|cat:"&context=$context"}
         {/if}