🔧 prevent missing index warnings
This commit is contained in:
parent
0ba0674412
commit
968bb9d831
3 changed files with 9 additions and 7 deletions
|
@ -27,11 +27,13 @@ class CRM_TwingleCampaign_BAO_TwingleEvent extends Campaign {
|
|||
$this->id_custom_field = Cache::getInstance()
|
||||
->getCustomFieldMapping()['twingle_event_id'];
|
||||
|
||||
try {
|
||||
$this->values['parent_id'] = $this->getParentCampaignId();
|
||||
} catch (CiviCRM_API3_Exception $e) {
|
||||
$errorMessage = $e->getMessage();
|
||||
throw new Exception("Could not identify parent Campaign: $errorMessage");
|
||||
if (isset($this->values['parent_id'])) {
|
||||
try {
|
||||
$this->values['parent_id'] = $this->getParentCampaignId();
|
||||
} catch (CiviCRM_API3_Exception $e) {
|
||||
$errorMessage = $e->getMessage();
|
||||
throw new Exception("Could not identify parent Campaign: $errorMessage");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue