Fix incorrect reference on extracted function
authoreileen <emcnaughton@wikimedia.org>
Sat, 16 Nov 2019 02:23:35 +0000 (15:23 +1300)
committereileen <emcnaughton@wikimedia.org>
Sat, 16 Nov 2019 02:23:35 +0000 (15:23 +1300)
Per https://github.com/civicrm/civicrm-core/pull/15803#pullrequestreview-317543503

CRM/Contact/BAO/Query.php

index 081ee78c96ca485e92e8473acedcbf4b0fdbb73c..1dc98f75045da2afe54307585ea1e62e2cf30fc2 100644 (file)
@@ -7217,10 +7217,10 @@ AND   displayRelType.is_active = 1
   public function handleWhereFromMetadata($fieldSpec, $name, $value, $op, $grouping = 0) {
     $this->_where[$grouping][] = CRM_Contact_BAO_Query::buildClause($fieldSpec['where'], $op, $value, CRM_Utils_Type::typeToString($fieldSpec['type']));
     $this->_qill[$grouping][] = $this->getQillForField($name, $value, $op, $fieldSpec);
-    if (!isset($query->_tables[$fieldSpec['table_name']])) {
+    if (!isset($this->_tables[$fieldSpec['table_name']])) {
       $this->_tables[$fieldSpec['table_name']] = 1;
     }
-    if (!isset($query->_whereTables[$fieldSpec['table_name']])) {
+    if (!isset($this->_whereTables[$fieldSpec['table_name']])) {
       $this->_whereTables[$fieldSpec['table_name']] = 1;
     }
   }