Skip to content

Commit

Permalink
Merge pull request #200 from TheDMSGroup/ENG-814
Browse files Browse the repository at this point in the history
[ENG-814] Fix memory leaks on batch processing
  • Loading branch information
heathdutton authored Mar 25, 2019
2 parents 8513f6b + 76acbd8 commit c74f9ab
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Model/Cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ public function create()
}
if (count($entities)) {
$this->getRepository()->saveEntities($entities);
$this->em->clear('MauticPlugin\MauticContactClientBundle\Entity\Cache');
}
}

Expand Down Expand Up @@ -149,6 +150,7 @@ private function getUtmSource()
if (!$this->utmSource) {
$utmHelper = $this->getContainer()->get('mautic.contactclient.helper.utmsource');
$this->utmSource = $utmHelper->getFirstUtmSource($this->contact);
$this->em->clear('Mautic\LeadBundle\Entity\UtmTag');
}

return $this->utmSource;
Expand Down

0 comments on commit c74f9ab

Please sign in to comment.