code cleaning

removed unnecessary code
This commit is contained in:
Marc Michalsky forumZFD 2020-10-13 09:09:39 +02:00
parent 39fa2cc603
commit 18100e866b
Signed by untrusted user who does not match committer: marc.koch
GPG key ID: 12406554CFB028B9
2 changed files with 4 additions and 11 deletions

View file

@ -43,7 +43,8 @@ class CRM_TwingleCampaign_Upgrader extends CRM_TwingleCampaign_Upgrader_Base {
// Create campaign types, custom fields and custom groups by the contents // Create campaign types, custom fields and custom groups by the contents
// of the json file "campaigns.json" // of the json file "campaigns.json"
$json_file = file_get_contents(E::path() . '/CRM/TwingleCampaign/Upgrader/resources/campaigns.json'); $json_file = file_get_contents(E::path() .
'/CRM/TwingleCampaign/Upgrader/resources/campaigns.json');
$campaign_info = json_decode($json_file, TRUE); $campaign_info = json_decode($json_file, TRUE);
if (!$campaign_info) { if (!$campaign_info) {

View file

@ -74,7 +74,6 @@ class TwingleProject {
// Translate keys for import // Translate keys for import
self::translateKeys($project, self::IN); self::translateKeys($project, self::IN);
self::translateKeys($options, self::IN);
// Format values for import // Format values for import
self::formatValues($project, self::IN); self::formatValues($project, self::IN);
@ -212,13 +211,6 @@ class TwingleProject {
// Update attributes // Update attributes
$this->values = array_merge($this->values, $values); $this->values = array_merge($this->values, $values);
// Translate Twingle field names into custom field names
$translatedFields = $this->values;
self::translateCustomFields($translatedFields, self::IN);
// Set id
$translatedFields['id'] = $this->id;
} }