diff options
author | Thomas Steur <thomas.steur@googlemail.com> | 2014-09-30 09:37:32 +0400 |
---|---|---|
committer | Thomas Steur <thomas.steur@googlemail.com> | 2014-09-30 09:37:32 +0400 |
commit | a00487b0b841c4b15463b591c7f62176c4b84d15 (patch) | |
tree | 6eb893ce356a4740e044c9cdadaf84ffb2095b9d /plugins/Referrers/Columns | |
parent | 0edef3332289a7cbe54b58084b967907d1086d29 (diff) |
coding style fixes, some PHPStorm inspection fixes, improved readability of code, few refactorings, all as part of our code cleanup strategy
Diffstat (limited to 'plugins/Referrers/Columns')
-rw-r--r-- | plugins/Referrers/Columns/Base.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/Referrers/Columns/Base.php b/plugins/Referrers/Columns/Base.php index de871401b3..a69fcc54bf 100644 --- a/plugins/Referrers/Columns/Base.php +++ b/plugins/Referrers/Columns/Base.php @@ -244,14 +244,14 @@ abstract class Base extends VisitDimension protected function detectCampaignKeywordFromReferrerUrl() { - if(!empty($this->nameReferrerAnalyzed) + if (!empty($this->nameReferrerAnalyzed) && !empty($this->keywordReferrerAnalyzed)) { // keyword is already set, we skip return true; } // Set the Campaign keyword to the keyword found in the Referrer URL if any - if(!empty($this->nameReferrerAnalyzed)) { + if (!empty($this->nameReferrerAnalyzed)) { $referrerUrlInfo = UrlHelper::extractSearchEngineInformationFromUrl($this->referrerUrl); if (!empty($referrerUrlInfo['keywords'])) { $this->keywordReferrerAnalyzed = $referrerUrlInfo['keywords']; @@ -270,7 +270,7 @@ abstract class Base extends VisitDimension $parsedAdsenseReferrerUrl = parse_url($value); if (!empty($parsedAdsenseReferrerUrl['host'])) { - if(empty($this->nameReferrerAnalyzed)) { + if (empty($this->nameReferrerAnalyzed)) { $type = $this->getParameterValueFromReferrerUrl('ad_type'); $type = $type ? " ($type)" : ''; $this->nameReferrerAnalyzed = self::LABEL_ADWORDS_NAME . $type; @@ -304,7 +304,7 @@ abstract class Base extends VisitDimension return false; } // if we detected a campaign but there is still no keyword set, we set the keyword to the Referrer host - if(empty($this->keywordReferrerAnalyzed)) { + if (empty($this->keywordReferrerAnalyzed)) { $this->keywordReferrerAnalyzed = $this->referrerHost; } |