@@ -71,7 +71,7 @@ |
||
| 71 | 71 | } |
| 72 | 72 | } |
| 73 | 73 | |
| 74 | - if (! is_array($configurationArray)) { |
|
| 74 | + if (!is_array($configurationArray)) { |
|
| 75 | 75 | $configurationArray = array(); |
| 76 | 76 | } |
| 77 | 77 | |
@@ -255,8 +255,8 @@ discard block |
||
| 255 | 255 | */ |
| 256 | 256 | public function getCssFileByFileKey($fileKey, $defaultIfEmpty = '') |
| 257 | 257 | { |
| 258 | - $cssFileName = $this->getValueByPathOrDefaultValue('plugin.tx_solr.cssFiles.' . $fileKey, $defaultIfEmpty); |
|
| 259 | - return (string) $cssFileName; |
|
| 258 | + $cssFileName = $this->getValueByPathOrDefaultValue('plugin.tx_solr.cssFiles.' . $fileKey, $defaultIfEmpty); |
|
| 259 | + return (string)$cssFileName; |
|
| 260 | 260 | } |
| 261 | 261 | |
| 262 | 262 | /** |
@@ -565,8 +565,8 @@ discard block |
||
| 565 | 565 | */ |
| 566 | 566 | public function getJavaScriptFileByFileKey($fileKey, $defaultIfEmpty = '') |
| 567 | 567 | { |
| 568 | - $javaScriptFileName = $this->getValueByPathOrDefaultValue('plugin.tx_solr.javascriptFiles.' . $fileKey, $defaultIfEmpty); |
|
| 569 | - return (string) $javaScriptFileName; |
|
| 568 | + $javaScriptFileName = $this->getValueByPathOrDefaultValue('plugin.tx_solr.javascriptFiles.' . $fileKey, $defaultIfEmpty); |
|
| 569 | + return (string)$javaScriptFileName; |
|
| 570 | 570 | } |
| 571 | 571 | |
| 572 | 572 | /** |
@@ -579,8 +579,8 @@ discard block |
||
| 579 | 579 | */ |
| 580 | 580 | public function getJavaScriptLoadIn($defaultIfEmpty = 'footer') |
| 581 | 581 | { |
| 582 | - $loadIn = $this->getValueByPathOrDefaultValue('plugin.tx_solr.javascriptFiles.loadIn', $defaultIfEmpty); |
|
| 583 | - return (string) $loadIn; |
|
| 582 | + $loadIn = $this->getValueByPathOrDefaultValue('plugin.tx_solr.javascriptFiles.loadIn', $defaultIfEmpty); |
|
| 583 | + return (string)$loadIn; |
|
| 584 | 584 | } |
| 585 | 585 | |
| 586 | 586 | /** |
@@ -927,7 +927,7 @@ discard block |
||
| 927 | 927 | public function getSearchVariantsLimit($defaultIfEmpty = 10) |
| 928 | 928 | { |
| 929 | 929 | $result = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.variants.limit', $defaultIfEmpty); |
| 930 | - return (int) $result; |
|
| 930 | + return (int)$result; |
|
| 931 | 931 | } |
| 932 | 932 | |
| 933 | 933 | /** |
@@ -969,7 +969,7 @@ discard block |
||
| 969 | 969 | public function getSearchFrequentSearchesMinSize($defaultIfEmpty = 14) |
| 970 | 970 | { |
| 971 | 971 | $result = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.frequentSearches.minSize', $defaultIfEmpty); |
| 972 | - return (int) $result; |
|
| 972 | + return (int)$result; |
|
| 973 | 973 | } |
| 974 | 974 | |
| 975 | 975 | /** |
@@ -983,7 +983,7 @@ discard block |
||
| 983 | 983 | public function getSearchFrequentSearchesMaxSize($defaultIfEmpty = 32) |
| 984 | 984 | { |
| 985 | 985 | $result = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.frequentSearches.maxSize', $defaultIfEmpty); |
| 986 | - return (int) $result; |
|
| 986 | + return (int)$result; |
|
| 987 | 987 | } |
| 988 | 988 | |
| 989 | 989 | /** |
@@ -1025,7 +1025,7 @@ discard block |
||
| 1025 | 1025 | public function getSearchInitializeWithQuery($defaultIfEmpty = '') |
| 1026 | 1026 | { |
| 1027 | 1027 | $result = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.initializeWithQuery', $defaultIfEmpty); |
| 1028 | - return (string) $result; |
|
| 1028 | + return (string)$result; |
|
| 1029 | 1029 | } |
| 1030 | 1030 | |
| 1031 | 1031 | /** |
@@ -1053,7 +1053,7 @@ discard block |
||
| 1053 | 1053 | public function getSearchLastSearchesMode($defaultIfEmpty = 'user') |
| 1054 | 1054 | { |
| 1055 | 1055 | $result = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.lastSearches.mode', $defaultIfEmpty); |
| 1056 | - return (string) $result; |
|
| 1056 | + return (string)$result; |
|
| 1057 | 1057 | } |
| 1058 | 1058 | |
| 1059 | 1059 | /** |
@@ -1067,7 +1067,7 @@ discard block |
||
| 1067 | 1067 | public function getSearchLastSearchesLimit($defaultIfEmpty = 10) |
| 1068 | 1068 | { |
| 1069 | 1069 | $result = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.lastSearches.limit', $defaultIfEmpty); |
| 1070 | - return (int) $result; |
|
| 1070 | + return (int)$result; |
|
| 1071 | 1071 | } |
| 1072 | 1072 | |
| 1073 | 1073 | /** |
@@ -1321,7 +1321,7 @@ discard block |
||
| 1321 | 1321 | */ |
| 1322 | 1322 | public function getSearchTargetPage() |
| 1323 | 1323 | { |
| 1324 | - $targetPage = (int) $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.targetPage', 0); |
|
| 1324 | + $targetPage = (int)$this->getValueByPathOrDefaultValue('plugin.tx_solr.search.targetPage', 0); |
|
| 1325 | 1325 | if ($targetPage === 0) { |
| 1326 | 1326 | // when no specific page was configured we use the contextPageId (which is usual $GLOBALS['TSFE']->id) |
| 1327 | 1327 | $targetPage = $this->contextPageId; |
@@ -1414,7 +1414,7 @@ discard block |
||
| 1414 | 1414 | */ |
| 1415 | 1415 | public function getSearchResultsPerPage($defaultIfEmpty = 10) |
| 1416 | 1416 | { |
| 1417 | - return (int) $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.results.resultsPerPage', $defaultIfEmpty); |
|
| 1417 | + return (int)$this->getValueByPathOrDefaultValue('plugin.tx_solr.search.results.resultsPerPage', $defaultIfEmpty); |
|
| 1418 | 1418 | } |
| 1419 | 1419 | |
| 1420 | 1420 | /** |
@@ -1459,7 +1459,7 @@ discard block |
||
| 1459 | 1459 | */ |
| 1460 | 1460 | public function getSearchSpellchecking($defaultIfEmpty = false) |
| 1461 | 1461 | { |
| 1462 | - $isFacetingEnabled = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.spellchecking', $defaultIfEmpty); |
|
| 1462 | + $isFacetingEnabled = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.spellchecking', $defaultIfEmpty); |
|
| 1463 | 1463 | return $this->getBool($isFacetingEnabled); |
| 1464 | 1464 | } |
| 1465 | 1465 | |
@@ -1473,7 +1473,7 @@ discard block |
||
| 1473 | 1473 | */ |
| 1474 | 1474 | public function getSearchSpellcheckingWrap($defaultIfEmpty = '') |
| 1475 | 1475 | { |
| 1476 | - return (string) $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.spellchecking.wrap', $defaultIfEmpty); |
|
| 1476 | + return (string)$this->getValueByPathOrDefaultValue('plugin.tx_solr.search.spellchecking.wrap', $defaultIfEmpty); |
|
| 1477 | 1477 | } |
| 1478 | 1478 | |
| 1479 | 1479 | /** |
@@ -1486,7 +1486,7 @@ discard block |
||
| 1486 | 1486 | */ |
| 1487 | 1487 | public function getSearchSpellcheckingNumberOfSuggestionsToTry($defaultIfEmpty = 0) |
| 1488 | 1488 | { |
| 1489 | - return (int) $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.spellchecking.numberOfSuggestionsToTry', $defaultIfEmpty); |
|
| 1489 | + return (int)$this->getValueByPathOrDefaultValue('plugin.tx_solr.search.spellchecking.numberOfSuggestionsToTry', $defaultIfEmpty); |
|
| 1490 | 1490 | } |
| 1491 | 1491 | |
| 1492 | 1492 | /** |
@@ -1513,7 +1513,7 @@ discard block |
||
| 1513 | 1513 | */ |
| 1514 | 1514 | public function getSearchFaceting($defaultIfEmpty = false) |
| 1515 | 1515 | { |
| 1516 | - $isFacetingEnabled = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting', $defaultIfEmpty); |
|
| 1516 | + $isFacetingEnabled = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting', $defaultIfEmpty); |
|
| 1517 | 1517 | return $this->getBool($isFacetingEnabled); |
| 1518 | 1518 | } |
| 1519 | 1519 | |
@@ -1559,7 +1559,7 @@ discard block |
||
| 1559 | 1559 | */ |
| 1560 | 1560 | public function getSearchFacetingRemoveFacetLinkText($defaultIfEmpty = '@facetLabel: @facetText') |
| 1561 | 1561 | { |
| 1562 | - return (string) $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.removeFacetLinkText', $defaultIfEmpty); |
|
| 1562 | + return (string)$this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.removeFacetLinkText', $defaultIfEmpty); |
|
| 1563 | 1563 | } |
| 1564 | 1564 | |
| 1565 | 1565 | /** |
@@ -1603,7 +1603,7 @@ discard block |
||
| 1603 | 1603 | */ |
| 1604 | 1604 | public function getSearchFacetingShowAllLinkWrap($defaultIfEmpty = '') |
| 1605 | 1605 | { |
| 1606 | - return (string) $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.showAllLink.wrap', $defaultIfEmpty); |
|
| 1606 | + return (string)$this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.showAllLink.wrap', $defaultIfEmpty); |
|
| 1607 | 1607 | } |
| 1608 | 1608 | |
| 1609 | 1609 | /** |
@@ -1631,7 +1631,7 @@ discard block |
||
| 1631 | 1631 | */ |
| 1632 | 1632 | public function getSearchFacetingFacetLinkUrlParametersUseForFacetResetLinkUrl($defaultIfEmpty = true) |
| 1633 | 1633 | { |
| 1634 | - $useForFacetResetLinkUrl = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.facetLinkUrlParameters.useForFacetResetLinkUrl', $defaultIfEmpty); |
|
| 1634 | + $useForFacetResetLinkUrl = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.facetLinkUrlParameters.useForFacetResetLinkUrl', $defaultIfEmpty); |
|
| 1635 | 1635 | return $this->getBool($useForFacetResetLinkUrl); |
| 1636 | 1636 | } |
| 1637 | 1637 | |
@@ -1663,7 +1663,7 @@ discard block |
||
| 1663 | 1663 | */ |
| 1664 | 1664 | public function getSearchFacetingMinimumCount($defaultIfEmpty = 1) |
| 1665 | 1665 | { |
| 1666 | - return (int) $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.minimumCount', $defaultIfEmpty); |
|
| 1666 | + return (int)$this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.minimumCount', $defaultIfEmpty); |
|
| 1667 | 1667 | } |
| 1668 | 1668 | |
| 1669 | 1669 | /** |
@@ -1676,7 +1676,7 @@ discard block |
||
| 1676 | 1676 | */ |
| 1677 | 1677 | public function getSearchFacetingLimit($defaultIfEmpty = 10) |
| 1678 | 1678 | { |
| 1679 | - return (int) $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.limit', $defaultIfEmpty); |
|
| 1679 | + return (int)$this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.limit', $defaultIfEmpty); |
|
| 1680 | 1680 | } |
| 1681 | 1681 | |
| 1682 | 1682 | /** |
@@ -1689,7 +1689,7 @@ discard block |
||
| 1689 | 1689 | */ |
| 1690 | 1690 | public function getSearchFacetingSingleFacetMode($defaultIfEmpty = false) |
| 1691 | 1691 | { |
| 1692 | - $singleFacetMode = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.singleFacetMode', $defaultIfEmpty); |
|
| 1692 | + $singleFacetMode = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.singleFacetMode', $defaultIfEmpty); |
|
| 1693 | 1693 | return $this->getBool($singleFacetMode); |
| 1694 | 1694 | } |
| 1695 | 1695 | |
@@ -1719,7 +1719,7 @@ discard block |
||
| 1719 | 1719 | */ |
| 1720 | 1720 | public function getSearchFacetingKeepAllFacetsOnSelection($defaultIfEmpty = false) |
| 1721 | 1721 | { |
| 1722 | - $keepAllOptionsOnSelection = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.keepAllFacetsOnSelection', $defaultIfEmpty); |
|
| 1722 | + $keepAllOptionsOnSelection = $this->getValueByPathOrDefaultValue('plugin.tx_solr.search.faceting.keepAllFacetsOnSelection', $defaultIfEmpty); |
|
| 1723 | 1723 | return $this->getBool($keepAllOptionsOnSelection); |
| 1724 | 1724 | } |
| 1725 | 1725 | |
@@ -1761,7 +1761,7 @@ discard block |
||
| 1761 | 1761 | */ |
| 1762 | 1762 | public function getStatistics($defaultIfEmpty = false) |
| 1763 | 1763 | { |
| 1764 | - $isFacetingEnabled = $this->getValueByPathOrDefaultValue('plugin.tx_solr.statistics', $defaultIfEmpty); |
|
| 1764 | + $isFacetingEnabled = $this->getValueByPathOrDefaultValue('plugin.tx_solr.statistics', $defaultIfEmpty); |
|
| 1765 | 1765 | return $this->getBool($isFacetingEnabled); |
| 1766 | 1766 | } |
| 1767 | 1767 | |
@@ -1777,8 +1777,8 @@ discard block |
||
| 1777 | 1777 | */ |
| 1778 | 1778 | public function getStatisticsAnonymizeIP($defaultIfEmpty = 0) |
| 1779 | 1779 | { |
| 1780 | - $anomizeToLength = $this->getValueByPathOrDefaultValue('plugin.tx_solr.statistics.anonymizeIP', $defaultIfEmpty); |
|
| 1781 | - return (int) $anomizeToLength; |
|
| 1780 | + $anomizeToLength = $this->getValueByPathOrDefaultValue('plugin.tx_solr.statistics.anonymizeIP', $defaultIfEmpty); |
|
| 1781 | + return (int)$anomizeToLength; |
|
| 1782 | 1782 | } |
| 1783 | 1783 | |
| 1784 | 1784 | /** |
@@ -1791,7 +1791,7 @@ discard block |
||
| 1791 | 1791 | */ |
| 1792 | 1792 | public function getSuggest($defaultIfEmpty = false) |
| 1793 | 1793 | { |
| 1794 | - $isSuggestionEnabled = $this->getValueByPathOrDefaultValue('plugin.tx_solr.suggest', $defaultIfEmpty); |
|
| 1794 | + $isSuggestionEnabled = $this->getValueByPathOrDefaultValue('plugin.tx_solr.suggest', $defaultIfEmpty); |
|
| 1795 | 1795 | return $this->getBool($isSuggestionEnabled); |
| 1796 | 1796 | } |
| 1797 | 1797 | |
@@ -1805,7 +1805,7 @@ discard block |
||
| 1805 | 1805 | */ |
| 1806 | 1806 | public function getSuggestForceHttps($defaultIfEmpty = false) |
| 1807 | 1807 | { |
| 1808 | - $isHttpsForced = $this->getValueByPathOrDefaultValue('plugin.tx_solr.suggest.forceHttps', $defaultIfEmpty); |
|
| 1808 | + $isHttpsForced = $this->getValueByPathOrDefaultValue('plugin.tx_solr.suggest.forceHttps', $defaultIfEmpty); |
|
| 1809 | 1809 | return $this->getBool($isHttpsForced); |
| 1810 | 1810 | } |
| 1811 | 1811 | |
@@ -1821,8 +1821,8 @@ discard block |
||
| 1821 | 1821 | */ |
| 1822 | 1822 | public function getTemplateByFileKey($fileKey, $defaultIfEmpty = '') |
| 1823 | 1823 | { |
| 1824 | - $templateFileName = $this->getValueByPathOrDefaultValue('plugin.tx_solr.templateFiles.' . $fileKey, $defaultIfEmpty); |
|
| 1825 | - return (string) $templateFileName; |
|
| 1824 | + $templateFileName = $this->getValueByPathOrDefaultValue('plugin.tx_solr.templateFiles.' . $fileKey, $defaultIfEmpty); |
|
| 1825 | + return (string)$templateFileName; |
|
| 1826 | 1826 | } |
| 1827 | 1827 | |
| 1828 | 1828 | /** |
@@ -1835,7 +1835,7 @@ discard block |
||
| 1835 | 1835 | */ |
| 1836 | 1836 | public function getViewHelpersCropConfiguration(array $defaultIfEmpty = array()) |
| 1837 | 1837 | { |
| 1838 | - $cropViewHelperConfiguration = $this->getObjectByPathOrDefault('plugin.tx_solr.viewHelpers.crop.', $defaultIfEmpty); |
|
| 1838 | + $cropViewHelperConfiguration = $this->getObjectByPathOrDefault('plugin.tx_solr.viewHelpers.crop.', $defaultIfEmpty); |
|
| 1839 | 1839 | return $cropViewHelperConfiguration; |
| 1840 | 1840 | } |
| 1841 | 1841 | |
@@ -1849,7 +1849,7 @@ discard block |
||
| 1849 | 1849 | */ |
| 1850 | 1850 | public function getViewHelpersSortIndicatorConfiguration(array $defaultIfEmpty = array()) |
| 1851 | 1851 | { |
| 1852 | - $sortingViewHelperConfiguration = $this->getObjectByPathOrDefault('plugin.tx_solr.viewHelpers.sortIndicator.', $defaultIfEmpty); |
|
| 1852 | + $sortingViewHelperConfiguration = $this->getObjectByPathOrDefault('plugin.tx_solr.viewHelpers.sortIndicator.', $defaultIfEmpty); |
|
| 1853 | 1853 | return $sortingViewHelperConfiguration; |
| 1854 | 1854 | } |
| 1855 | 1855 | } |
@@ -60,7 +60,7 @@ |
||
| 60 | 60 | } |
| 61 | 61 | |
| 62 | 62 | if (isset($cropConfiguration['cropFullWords'])) { |
| 63 | - $this->cropFullWords = (boolean) $cropConfiguration ['cropFullWords']; |
|
| 63 | + $this->cropFullWords = (boolean)$cropConfiguration ['cropFullWords']; |
|
| 64 | 64 | } |
| 65 | 65 | } |
| 66 | 66 | |
@@ -53,14 +53,14 @@ |
||
| 53 | 53 | public function execute(array $arguments = array()) |
| 54 | 54 | { |
| 55 | 55 | try { |
| 56 | - $iterator = unserialize($arguments[0]); |
|
| 56 | + $iterator = unserialize($arguments[0]); |
|
| 57 | 57 | } catch (\Exception $e) { |
| 58 | 58 | $iterator = []; |
| 59 | 59 | } |
| 60 | 60 | if ($iterator === false) { |
| 61 | 61 | $iterator = []; |
| 62 | 62 | } |
| 63 | - $variable = $arguments[1]; |
|
| 63 | + $variable = $arguments[1]; |
|
| 64 | 64 | |
| 65 | 65 | $data = ''; |
| 66 | 66 | foreach ($iterator as $value) { |
@@ -218,7 +218,7 @@ |
||
| 218 | 218 | $ucHelperKey = Util::underscoredToUpperCamelCase($helperKey); |
| 219 | 219 | $vendorNameSpace = 'ApacheSolrForTypo3\\Solr\\'; |
| 220 | 220 | $possibleFilename = $ucHelperKey . '.php'; |
| 221 | - $possibleClassName = $vendorNameSpace . str_replace('/', '\\', |
|
| 221 | + $possibleClassName = $vendorNameSpace . str_replace('/', '\\', |
|
| 222 | 222 | $viewHelperRealPath) . '\\' . $ucHelperKey; |
| 223 | 223 | |
| 224 | 224 | $viewHelperIncludePath = ExtensionManagementUtility::extPath($extensionKey) |
@@ -46,9 +46,9 @@ discard block |
||
| 46 | 46 | public function getSearchStatistics($rootPageId, $days = 30, $limit = 10) |
| 47 | 47 | { |
| 48 | 48 | $now = time(); |
| 49 | - $timeStart = (int) ($now - 86400 * intval($days)); // 86400 seconds/day |
|
| 50 | - $rootPageId = (int) $rootPageId; |
|
| 51 | - $limit = (int) $limit; |
|
| 49 | + $timeStart = (int)($now - 86400 * intval($days)); // 86400 seconds/day |
|
| 50 | + $rootPageId = (int)$rootPageId; |
|
| 51 | + $limit = (int)$limit; |
|
| 52 | 52 | |
| 53 | 53 | $statisticsRows = $this->getDatabase()->exec_SELECTgetRows( |
| 54 | 54 | 'keywords, count(keywords) as count, num_found as hits', |
@@ -66,7 +66,7 @@ discard block |
||
| 66 | 66 | $sumCount += $statisticsRow['count']; |
| 67 | 67 | } |
| 68 | 68 | |
| 69 | - $statisticsRows = array_map(function ($row) use ($sumCount) { |
|
| 69 | + $statisticsRows = array_map(function($row) use ($sumCount) { |
|
| 70 | 70 | $row['percent'] = $row['count'] * 100 / $sumCount; |
| 71 | 71 | |
| 72 | 72 | return $row; |
@@ -112,9 +112,9 @@ discard block |
||
| 112 | 112 | */ |
| 113 | 113 | protected function getTopKeyWordsWithOrWithoutHits($rootPageId, $days = 30, $limit, $withoutHits) |
| 114 | 114 | { |
| 115 | - $rootPageId = (int) $rootPageId; |
|
| 116 | - $limit = (int) $limit; |
|
| 117 | - $withoutHits = (bool) $withoutHits; |
|
| 115 | + $rootPageId = (int)$rootPageId; |
|
| 116 | + $limit = (int)$limit; |
|
| 117 | + $withoutHits = (bool)$withoutHits; |
|
| 118 | 118 | |
| 119 | 119 | $now = time(); |
| 120 | 120 | $timeStart = $now - 86400 * intval($days); // 86400 seconds/day |
@@ -159,7 +159,7 @@ discard block |
||
| 159 | 159 | |
| 160 | 160 | // for the hits we need to take the average |
| 161 | 161 | $avgHits = $this->getAverageFromField($mergedRow, $statisticsRow, 'hits'); |
| 162 | - $mergedRow['hits'] = (int) $avgHits; |
|
| 162 | + $mergedRow['hits'] = (int)$avgHits; |
|
| 163 | 163 | |
| 164 | 164 | // for the count we need to take the sum, because it's the sum of searches |
| 165 | 165 | $mergedRow['count'] = $mergedRow['count'] + $statisticsRow['count']; |
@@ -203,7 +203,7 @@ discard block |
||
| 203 | 203 | * @param array $statisticsRow |
| 204 | 204 | * @return float|int |
| 205 | 205 | */ |
| 206 | - protected function getAverageFromField(array &$mergedRow, array $statisticsRow, $fieldName) |
|
| 206 | + protected function getAverageFromField(array &$mergedRow, array $statisticsRow, $fieldName) |
|
| 207 | 207 | { |
| 208 | 208 | // when this is the first row we can take it. |
| 209 | 209 | if ($mergedRow['mergedrows'] === 1) { |
@@ -157,7 +157,7 @@ |
||
| 157 | 157 | */ |
| 158 | 158 | public function __construct($keywords, $solrConfiguration = null) |
| 159 | 159 | { |
| 160 | - $keywords = (string) $keywords; |
|
| 160 | + $keywords = (string)$keywords; |
|
| 161 | 161 | if ($solrConfiguration == null) { |
| 162 | 162 | $this->solrConfiguration = Util::getSolrConfiguration(); |
| 163 | 163 | } else { |
@@ -157,7 +157,7 @@ |
||
| 157 | 157 | */ |
| 158 | 158 | public function __construct($keywords, $solrConfiguration = null) |
| 159 | 159 | { |
| 160 | - $keywords = (string) $keywords; |
|
| 160 | + $keywords = (string)$keywords; |
|
| 161 | 161 | if ($solrConfiguration == null) { |
| 162 | 162 | $this->solrConfiguration = Util::getSolrConfiguration(); |
| 163 | 163 | } else { |
@@ -199,7 +199,7 @@ discard block |
||
| 199 | 199 | { |
| 200 | 200 | try { |
| 201 | 201 | $pingQueryTime = $solr->getPingRoundTripRuntime(); |
| 202 | - $pingMessage = (int) $pingQueryTime . ' ms'; |
|
| 202 | + $pingMessage = (int)$pingQueryTime . ' ms'; |
|
| 203 | 203 | } catch (PingFailedException $e) { |
| 204 | 204 | $this->responseStatus = Status::ERROR; |
| 205 | 205 | $pingMessage = 'Ping error: ' . $e->getMessage(); |
@@ -217,7 +217,7 @@ discard block |
||
| 217 | 217 | try { |
| 218 | 218 | $solrConfigMessage = $solr->getSolrconfigName(); |
| 219 | 219 | } catch (\Exception $e) { |
| 220 | - $this->responseStatus = Status::ERROR; |
|
| 220 | + $this->responseStatus = Status::ERROR; |
|
| 221 | 221 | $solrConfigMessage = 'Error determining solr config: ' . $e->getMessage(); |
| 222 | 222 | } |
| 223 | 223 | |
@@ -234,7 +234,7 @@ discard block |
||
| 234 | 234 | try { |
| 235 | 235 | $solrSchemaMessage = $solr->getSchemaName(); |
| 236 | 236 | } catch (\Exception $e) { |
| 237 | - $this->responseStatus = Status::ERROR; |
|
| 237 | + $this->responseStatus = Status::ERROR; |
|
| 238 | 238 | $solrSchemaMessage = 'Error determining schema name: ' . $e->getMessage(); |
| 239 | 239 | } |
| 240 | 240 | |