From ac50ae375d787e25afeb59bd9fac6de2931b35c1 Mon Sep 17 00:00:00 2001 From: Coleman Watts Date: Tue, 26 Mar 2019 18:16:18 -0400 Subject: [PATCH] Don't expose condition to api.getoptions --- api/v3/Generic.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/v3/Generic.php b/api/v3/Generic.php index c88419ccb4..6dfb1c8138 100644 --- a/api/v3/Generic.php +++ b/api/v3/Generic.php @@ -432,7 +432,7 @@ function civicrm_api3_generic_getoptions($apiRequest) { // Validate 'context' from params $context = CRM_Utils_Array::value('context', $apiRequest['params']); CRM_Core_DAO::buildOptionsContext($context); - unset($apiRequest['params']['context'], $apiRequest['params']['field']); + unset($apiRequest['params']['context'], $apiRequest['params']['field'], $apiRequest['params']['condition']); $baoName = _civicrm_api3_get_BAO($apiRequest['entity']); $options = $baoName::buildOptions($fieldName, $context, $apiRequest['params']); -- 2.25.1