diff --git a/typo3/sysext/backend/Classes/Clipboard/Clipboard.php b/typo3/sysext/backend/Classes/Clipboard/Clipboard.php index 814191de63f8107f0ae1851bee69d975d1bf4df4..1d95b77165c888ae84497bdebe9c7f9648484442 100644 --- a/typo3/sysext/backend/Classes/Clipboard/Clipboard.php +++ b/typo3/sysext/backend/Classes/Clipboard/Clipboard.php @@ -221,7 +221,7 @@ class Clipboard { if (is_array($CBarr)) { foreach ($CBarr as $k => $v) { $p = explode('|', $k); - if ((string) $p[0] != (string) $table || $removeDeselected && !$v) { + if ((string)$p[0] != (string)$table || $removeDeselected && !$v) { unset($CBarr[$k]); } } @@ -779,11 +779,11 @@ class Clipboard { if ($v) { list($table, $uid) = explode('|', $k); if ($table != '_FILE') { - if ((!$matchTable || (string) $table == (string) $matchTable) && $GLOBALS['TCA'][$table]) { + if ((!$matchTable || (string)$table == (string)$matchTable) && $GLOBALS['TCA'][$table]) { $list[$k] = $pad == 'normal' ? $v : $uid; } } else { - if ((string) $table == (string) $matchTable) { + if ((string)$table == (string)$matchTable) { $list[$k] = $v; } } diff --git a/typo3/sysext/backend/Classes/Configuration/TypoScript/ConditionMatching/ConditionMatcher.php b/typo3/sysext/backend/Classes/Configuration/TypoScript/ConditionMatching/ConditionMatcher.php index 5b77e6f5e2acf5a3d65f5f7092ed56dc15691a37..1d36fb2e7809e0e49f863e1d7903b34d8f530a13 100644 --- a/typo3/sysext/backend/Classes/Configuration/TypoScript/ConditionMatching/ConditionMatcher.php +++ b/typo3/sysext/backend/Classes/Configuration/TypoScript/ConditionMatching/ConditionMatcher.php @@ -57,7 +57,7 @@ class ConditionMatcher extends \TYPO3\CMS\Core\Configuration\TypoScript\Conditio break; case 'adminUser': if ($this->isUserLoggedIn()) { - $result = !((bool) $value xor $this->isAdminUser()); + $result = !((bool)$value xor $this->isAdminUser()); return $result; } break; diff --git a/typo3/sysext/backend/Classes/ContextMenu/Extdirect/AbstractExtdirectContextMenu.php b/typo3/sysext/backend/Classes/ContextMenu/Extdirect/AbstractExtdirectContextMenu.php index 4928aec45eb67495f0c4eb7d486770ffafc3c77a..1735d29668fd77178e9c3231886ce632c8675f82 100644 --- a/typo3/sysext/backend/Classes/ContextMenu/Extdirect/AbstractExtdirectContextMenu.php +++ b/typo3/sysext/backend/Classes/ContextMenu/Extdirect/AbstractExtdirectContextMenu.php @@ -44,7 +44,7 @@ abstract class AbstractExtdirectContextMenu extends \TYPO3\CMS\Backend\ContextMe $this->setDataProvider($dataProvider); } /** @var $node \TYPO3\CMS\Backend\Tree\TreeNode */ - $node = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\TreeNode', (array) $nodeData); + $node = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\TreeNode', (array)$nodeData); $actions = $this->dataProvider->getActionsForNode($node); return $actions; } diff --git a/typo3/sysext/backend/Classes/ContextMenu/Pagetree/Extdirect/ContextMenuConfiguration.php b/typo3/sysext/backend/Classes/ContextMenu/Pagetree/Extdirect/ContextMenuConfiguration.php index 280745665814b759936926cc3dac66da276d2a04..eeb4ebbf9216548a6ba242089afef438b23f54e8 100644 --- a/typo3/sysext/backend/Classes/ContextMenu/Pagetree/Extdirect/ContextMenuConfiguration.php +++ b/typo3/sysext/backend/Classes/ContextMenu/Pagetree/Extdirect/ContextMenuConfiguration.php @@ -40,7 +40,7 @@ class ContextMenuConfiguration extends \TYPO3\CMS\Backend\ContextMenu\Extdirect\ */ public function getActionsForNodeArray($nodeData) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); $node->setRecord(\TYPO3\CMS\Backend\Tree\Pagetree\Commands::getNodeRecord($node->getId())); $this->initDataProvider(); $this->dataProvider->setContextMenuType('table.' . $node->getType()); diff --git a/typo3/sysext/backend/Classes/Controller/ContentElement/ElementInformationController.php b/typo3/sysext/backend/Classes/Controller/ContentElement/ElementInformationController.php index 125cc9c7a33f00a72748846ea2d257d5fcc832ca..0f264889fa03e5cc83b57c6f29f2288b48124d4f 100644 --- a/typo3/sysext/backend/Classes/Controller/ContentElement/ElementInformationController.php +++ b/typo3/sysext/backend/Classes/Controller/ContentElement/ElementInformationController.php @@ -133,7 +133,7 @@ class ElementInformationController { // Check permissions and uid value: if ($this->uid && $GLOBALS['BE_USER']->check('tables_select', $this->table)) { - if ((string) $this->table == 'pages') { + if ((string)$this->table == 'pages') { $this->pageinfo = BackendUtility::readPageAccess($this->uid, $this->perms_clause); $this->access = is_array($this->pageinfo) ? 1 : 0; $this->row = $this->pageinfo; diff --git a/typo3/sysext/backend/Classes/Controller/ContentElement/MoveElementController.php b/typo3/sysext/backend/Classes/Controller/ContentElement/MoveElementController.php index 5ebd4e39ce375967bcc956a485b8d15c64451f61..4d52bd7b02bf596bbe2f160a0206e4e89eb25650 100644 --- a/typo3/sysext/backend/Classes/Controller/ContentElement/MoveElementController.php +++ b/typo3/sysext/backend/Classes/Controller/ContentElement/MoveElementController.php @@ -139,7 +139,7 @@ class MoveElementController { // Reset variable to pick up the module content in: $code = ''; // IF the table is "pages": - if ((string) $this->table == 'pages') { + if ((string)$this->table == 'pages') { // Get page record (if accessible): $pageinfo = BackendUtility::readPageAccess($this->page_id, $this->perms_clause); if (is_array($pageinfo) && $GLOBALS['BE_USER']->isInWebMount($pageinfo['pid'], $this->perms_clause)) { @@ -162,7 +162,7 @@ class MoveElementController { } } // IF the table is "tt_content": - if ((string) $this->table == 'tt_content') { + if ((string)$this->table == 'tt_content') { // First, get the record: $tt_content_rec = BackendUtility::getRecord('tt_content', $this->moveUid); // ? @@ -245,9 +245,9 @@ class MoveElementController { 'back' => '' ); if ($this->page_id) { - if ((string) $this->table == 'pages') { + if ((string)$this->table == 'pages') { $buttons['csh'] = BackendUtility::cshItem('xMOD_csh_corebe', 'move_el_pages', $GLOBALS['BACK_PATH'], '', TRUE); - } elseif ((string) $this->table == 'tt_content') { + } elseif ((string)$this->table == 'tt_content') { $buttons['csh'] = BackendUtility::cshItem('xMOD_csh_corebe', 'move_el_cs', $GLOBALS['BACK_PATH'], '', TRUE); } if ($this->R_URI) { diff --git a/typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php b/typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php index a6d8b54a5a099097492caa4f20e0071c1918814a..2daf18cea8edb82a8cf998bedec2fb8b8909de14 100644 --- a/typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php +++ b/typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php @@ -353,7 +353,7 @@ class NewContentElementController { $showAll = $wizardGroup['show'] === '*'; $groupItems = array(); if (is_array($appendWizards[$groupKey . '.']['elements.'])) { - $wizardElements = array_merge((array) $wizardGroup['elements.'], $appendWizards[$groupKey . '.']['elements.']); + $wizardElements = array_merge((array)$wizardGroup['elements.'], $appendWizards[$groupKey . '.']['elements.']); } else { $wizardElements = $wizardGroup['elements.']; } diff --git a/typo3/sysext/backend/Classes/Controller/EditDocumentController.php b/typo3/sysext/backend/Classes/Controller/EditDocumentController.php index 3d45d582cee36646f530bcd4e41d03274cdccfb3..f302a95492e3e49ac091546f91be66af3bcc4242 100644 --- a/typo3/sysext/backend/Classes/Controller/EditDocumentController.php +++ b/typo3/sysext/backend/Classes/Controller/EditDocumentController.php @@ -864,7 +864,7 @@ class EditDocumentController { } // Check internals regarding access: $isRootLevelRestrictionIgnored = BackendUtility::isRootLevelRestrictionIgnored($table); - if ($hasAccess || (string) $calcPRec['pid'] === '0' && $isRootLevelRestrictionIgnored) { + if ($hasAccess || (string)$calcPRec['pid'] === '0' && $isRootLevelRestrictionIgnored) { $hasAccess = $GLOBALS['BE_USER']->recordEditAccessInternals($table, $calcPRec); $deniedAccessReason = $GLOBALS['BE_USER']->errorMsg; } diff --git a/typo3/sysext/backend/Classes/Controller/FileSystemNavigationFrameController.php b/typo3/sysext/backend/Classes/Controller/FileSystemNavigationFrameController.php index 2d473bc6e5052a2fb48728d9ef27f022cd54fb84..a0d58a51deb56fb6eefd12a79dea1210614e4a85 100644 --- a/typo3/sysext/backend/Classes/Controller/FileSystemNavigationFrameController.php +++ b/typo3/sysext/backend/Classes/Controller/FileSystemNavigationFrameController.php @@ -85,8 +85,8 @@ class FileSystemNavigationFrameController { $this->currentSubScript = GeneralUtility::_GP('currentSubScript'); $this->cMR = GeneralUtility::_GP('cMR'); - $scopeData = (string) GeneralUtility::_GP('scopeData'); - $scopeHash = (string) GeneralUtility::_GP('scopeHash'); + $scopeData = (string)GeneralUtility::_GP('scopeData'); + $scopeHash = (string)GeneralUtility::_GP('scopeHash'); if (!empty($scopeData) && GeneralUtility::hmac($scopeData) === $scopeHash) { $this->scopeData = unserialize($scopeData); diff --git a/typo3/sysext/backend/Classes/Controller/LoginController.php b/typo3/sysext/backend/Classes/Controller/LoginController.php index 4063e9e322433baa1313ee437d40ebbd6961d4c9..4eab5c7fc943d8817f0d77b9d634fb89e0a474b0 100644 --- a/typo3/sysext/backend/Classes/Controller/LoginController.php +++ b/typo3/sysext/backend/Classes/Controller/LoginController.php @@ -394,7 +394,7 @@ class LoginController { $this->redirectToURL = 'index.php?commandLI=setCookie'; } } - if ($redirectToURL = (string) $GLOBALS['BE_USER']->getTSConfigVal('auth.BE.redirectToURL')) { + if ($redirectToURL = (string)$GLOBALS['BE_USER']->getTSConfigVal('auth.BE.redirectToURL')) { $this->redirectToURL = $redirectToURL; $this->GPinterface = ''; } diff --git a/typo3/sysext/backend/Classes/Controller/SimpleDataHandlerController.php b/typo3/sysext/backend/Classes/Controller/SimpleDataHandlerController.php index 39971e9adddc36ac7b4c5b4945e072dbd85506cd..0bca4d4890b9120b4bbc79944f725a25cbd5f49e 100644 --- a/typo3/sysext/backend/Classes/Controller/SimpleDataHandlerController.php +++ b/typo3/sysext/backend/Classes/Controller/SimpleDataHandlerController.php @@ -29,7 +29,7 @@ use TYPO3\CMS\Core\Utility\GeneralUtility; class SimpleDataHandlerController { /** - * Array. Accepts options to be set in TCE object. Currently it supports "reverseOrder" (boolean). + * Array. Accepts options to be set in TCE object. Currently it supports "reverseOrder" (bool). * * @var array */ diff --git a/typo3/sysext/backend/Classes/Controller/Wizard/AddController.php b/typo3/sysext/backend/Classes/Controller/Wizard/AddController.php index 1034b3eaf8fa3240d83bdcbf54abd0690a85ae61..ba08a4676de498d3a487afc07d838f4ca3328770 100644 --- a/typo3/sysext/backend/Classes/Controller/Wizard/AddController.php +++ b/typo3/sysext/backend/Classes/Controller/Wizard/AddController.php @@ -162,7 +162,7 @@ class AddController { $flexToolObj = GeneralUtility::makeInstance('TYPO3\\CMS\\Core\\Configuration\\FlexForm\\FlexFormTools'); $curValueOfFlexform = $flexToolObj->getArrayValueByPath($this->P['flexFormPath'], $currentFlexFormData); $insertValue = ''; - switch ((string) $this->P['params']['setValue']) { + switch ((string)$this->P['params']['setValue']) { case 'set': $insertValue = $addEl; break; @@ -177,7 +177,7 @@ class AddController { $data[$this->P['table']][$this->P['uid']][$this->P['field']] = array(); $flexToolObj->setArrayValueByPath($this->P['flexFormPath'], $data[$this->P['table']][$this->P['uid']][$this->P['field']], $insertValue); } else { - switch ((string) $this->P['params']['setValue']) { + switch ((string)$this->P['params']['setValue']) { case 'set': $data[$this->P['table']][$this->P['uid']][$this->P['field']] = $addEl; break; diff --git a/typo3/sysext/backend/Classes/Controller/Wizard/FormsController.php b/typo3/sysext/backend/Classes/Controller/Wizard/FormsController.php index 343f3771c9d10caff23c9a91fc89709e34d4f2e2..eb29fae6222ce808392281a5824e6d9108f2bdee 100644 --- a/typo3/sysext/backend/Classes/Controller/Wizard/FormsController.php +++ b/typo3/sysext/backend/Classes/Controller/Wizard/FormsController.php @@ -415,7 +415,7 @@ class FormsController { $temp_cells[$GLOBALS['LANG']->getLL('forms_fieldName')] = '<input type="text"' . $this->doc->formWidth(10) . ' name="FORMCFG[c][' . ($k + 1) * 2 . '][fieldname]" value="' . htmlspecialchars($confData['fieldname']) . '" title="' . $GLOBALS['LANG']->getLL('forms_fieldName', TRUE) . '" />'; } // Field configuration depending on the fields type: - switch ((string) $confData['type']) { + switch ((string)$confData['type']) { case 'textarea': $temp_cells[$GLOBALS['LANG']->getLL('forms_cols')] = '<input type="text"' . $this->doc->formWidth(5) . ' name="FORMCFG[c][' . ($k + 1) * 2 . '][cols]" value="' . htmlspecialchars($confData['cols']) . '" title="' . $GLOBALS['LANG']->getLL('forms_cols', TRUE) . '" />'; $temp_cells[$GLOBALS['LANG']->getLL('forms_rows')] = '<input type="text"' . $this->doc->formWidth(5) . ' name="FORMCFG[c][' . ($k + 1) * 2 . '][rows]" value="' . htmlspecialchars($confData['rows']) . '" title="' . $GLOBALS['LANG']->getLL('forms_rows', TRUE) . '" />'; @@ -437,7 +437,7 @@ class FormsController { break; } // Field configuration depending on the fields type: - switch ((string) $confData['type']) { + switch ((string)$confData['type']) { case 'textarea': case 'input': @@ -651,7 +651,7 @@ class FormsController { $thisLine[1] = ($vv['required'] ? '*' : '') . str_replace(',', '', (($vv['fieldname'] ? $vv['fieldname'] . '=' : '') . $vv['type'])); // Default: $tArr = array('', '', '', '', '', ''); - switch ((string) $vv['type']) { + switch ((string)$vv['type']) { case 'textarea': if ((int)$vv['cols']) { $tArr[0] = (int)$vv['cols']; @@ -775,7 +775,7 @@ class FormsController { } else { $confData['fieldname'] = str_replace(' ', '_', trim($typeParts[0])); } - switch ((string) $confData['type']) { + switch ((string)$confData['type']) { case 'select': case 'radio': $confData['default'] = implode(LF, GeneralUtility::trimExplode(',', $parts[2])); @@ -784,7 +784,7 @@ class FormsController { $confData['default'] = trim($parts[2]); } // Field configuration depending on the fields type: - switch ((string) $confData['type']) { + switch ((string)$confData['type']) { case 'textarea': $confData['cols'] = $fParts[1]; $confData['rows'] = $fParts[2]; diff --git a/typo3/sysext/backend/Classes/Form/DataPreprocessor.php b/typo3/sysext/backend/Classes/Form/DataPreprocessor.php index 58727d5654da387043acd331ada9599db588548a..ecca4357433724150dd7fa75e4c7a4b1d6def5a5 100644 --- a/typo3/sysext/backend/Classes/Form/DataPreprocessor.php +++ b/typo3/sysext/backend/Classes/Form/DataPreprocessor.php @@ -96,7 +96,7 @@ class DataPreprocessor { $idList = $this->prevPageID; } if ($GLOBALS['TCA'][$table]) { - // For each ID value (integer) we + // For each ID value (int) we $ids = GeneralUtility::trimExplode(',', $idList, TRUE); foreach ($ids as $id) { // If ID is not blank: @@ -181,7 +181,7 @@ class DataPreprocessor { * The resulting, processed row is stored in $this->regTableItems_data[$uniqueItemRef], where $uniqueItemRef is "[tablename]_[id-value]" * * @param string $table The table name - * @param string $id The uid value of the record (integer). Can also be a string (NEW-something) if the record is a NEW record. + * @param string $id The uid value of the record (int). Can also be a string (NEW-something) if the record is a NEW record. * @param int $pid The pid integer. For existing records this is of course the row's "pid" field. For new records it can be either a page id (positive) or a pointer to another record from the SAME table (negative) after which the record should be inserted (or on same page) * @param array $row The row of the current record. If NEW record, then it may be loaded with default values (by eg. fetchRecord()). * @return void @@ -223,7 +223,7 @@ class DataPreprocessor { * The resulting, processed row will be returned. * * @param string $table The table name - * @param string $id The uid value of the record (integer). Can also be a string (NEW-something) if the record is a NEW record. + * @param string $id The uid value of the record (int). Can also be a string (NEW-something) if the record is a NEW record. * @param int $pid The pid integer. For existing records this is of course the row's "pid" field. For new records it can be either a page id (positive) or a pointer to another record from the SAME table (negative) after which the record should be inserted (or on same page) * @param array $row The row of the current record. If NEW record, then it may be loaded with default values (by eg. fetchRecord()). * @param array $TSconfig Tsconfig array diff --git a/typo3/sysext/backend/Classes/Form/Element/GroupElement.php b/typo3/sysext/backend/Classes/Form/Element/GroupElement.php index f2307819e0cc905118d2517a52a77e0308e8d735..2aa0dbfafdd2af26d0e8dadd9bd6341471e32ee0 100644 --- a/typo3/sysext/backend/Classes/Form/Element/GroupElement.php +++ b/typo3/sysext/backend/Classes/Form/Element/GroupElement.php @@ -75,7 +75,7 @@ class GroupElement extends AbstractFormElement { . '\', \'RemoveFirstIfFull\', \'' . $maxitems . '\'); ' . $additionalInformation['fieldChangeFunc']['TBE_EDITOR_fieldChanged']; } // Acting according to either "file" or "db" type: - switch ((string) $config['internal_type']) { + switch ((string)$config['internal_type']) { case 'file_reference': $config['uploadfolder'] = ''; // Fall through diff --git a/typo3/sysext/backend/Classes/Form/Element/InlineElement.php b/typo3/sysext/backend/Classes/Form/Element/InlineElement.php index c799f2ccfe520ef9c934e6ffa92d38c32c31e8f4..b9066128160e1ffda3e0c9c4859bec5479b54810 100644 --- a/typo3/sysext/backend/Classes/Form/Element/InlineElement.php +++ b/typo3/sysext/backend/Classes/Form/Element/InlineElement.php @@ -1276,7 +1276,7 @@ class InlineElement { * Handle AJAX calls to localize all records of a parent, localize a single record or to synchronize with the original language parent. * * @param string $domObjectId The calling object in hierarchy, that requested a new record. - * @param mixed $type Defines the type 'localize' or 'synchronize' (string) or a single uid to be localized (integer) + * @param mixed $type Defines the type 'localize' or 'synchronize' (string) or a single uid to be localized (int) * @return array An array to be used for JSON */ protected function synchronizeLocalizeRecords($domObjectId, $type) { @@ -1418,7 +1418,7 @@ class InlineElement { $top = $this->getStructureLevel(0); // Only do some action if the top record and the current record were saved before if (MathUtility::canBeInterpretedAsInteger($top['uid'])) { - $inlineView = (array) unserialize($GLOBALS['BE_USER']->uc['inlineView']); + $inlineView = (array)unserialize($GLOBALS['BE_USER']->uc['inlineView']); $inlineViewCurrent = &$inlineView[$top['table']][$top['uid']]; $expandUids = GeneralUtility::trimExplode(',', $expand); $collapseUids = GeneralUtility::trimExplode(',', $collapse); @@ -2463,7 +2463,7 @@ class InlineElement { */ static public function updateInlineView(&$uc, $tce) { if (isset($uc['inlineView']) && is_array($uc['inlineView'])) { - $inlineView = (array) unserialize($GLOBALS['BE_USER']->uc['inlineView']); + $inlineView = (array)unserialize($GLOBALS['BE_USER']->uc['inlineView']); foreach ($uc['inlineView'] as $topTable => $topRecords) { foreach ($topRecords as $topUid => $childElements) { foreach ($childElements as $childTable => $childRecords) { diff --git a/typo3/sysext/backend/Classes/Form/Element/SelectElement.php b/typo3/sysext/backend/Classes/Form/Element/SelectElement.php index 5e2b3124985bc2266986936d12c807282105d4e0..6321e7cffccb59a659393c3b1073142332625eb3 100644 --- a/typo3/sysext/backend/Classes/Form/Element/SelectElement.php +++ b/typo3/sysext/backend/Classes/Form/Element/SelectElement.php @@ -683,7 +683,7 @@ class SelectElement extends AbstractFormElement { } // Non-selectable element: $nonSel = ''; - if ((string) $p[1] === '--div--') { + if ((string)$p[1] === '--div--') { $nonSel = ' onclick="this.selected=0;" class="c-divider"'; } // Icon style for option tag: diff --git a/typo3/sysext/backend/Classes/Form/Element/SuggestDefaultReceiver.php b/typo3/sysext/backend/Classes/Form/Element/SuggestDefaultReceiver.php index 2c53c13c7d6a83f0016f55969c039d0125cd3c7b..6caf991a8d0c3d7743a4b872739e57704d5ed950 100644 --- a/typo3/sysext/backend/Classes/Form/Element/SuggestDefaultReceiver.php +++ b/typo3/sysext/backend/Classes/Form/Element/SuggestDefaultReceiver.php @@ -299,7 +299,7 @@ class SuggestDefaultReceiver { if (!BackendUtility::readPageAccess($uid, $GLOBALS['BE_USER']->getPagePermsClause(1))) { $retValue = FALSE; } - } elseif (isset($GLOBALS['TCA'][$table]['ctrl']['is_static']) && (bool) $GLOBALS['TCA'][$table]['ctrl']['is_static']) { + } elseif (isset($GLOBALS['TCA'][$table]['ctrl']['is_static']) && (bool)$GLOBALS['TCA'][$table]['ctrl']['is_static']) { $retValue = TRUE; } else { if (!is_array(BackendUtility::readPageAccess($row['pid'], $GLOBALS['BE_USER']->getPagePermsClause(1)))) { diff --git a/typo3/sysext/backend/Classes/Form/ElementConditionMatcher.php b/typo3/sysext/backend/Classes/Form/ElementConditionMatcher.php index 776f06a001cda4f1b56069c2da006a8c01adc939..4a410c6ad6e817e076e1859ee9b627d46882ddca 100644 --- a/typo3/sysext/backend/Classes/Form/ElementConditionMatcher.php +++ b/typo3/sysext/backend/Classes/Form/ElementConditionMatcher.php @@ -194,7 +194,7 @@ class ElementConditionMatcher { switch ($operator) { case 'REQ': if (strtoupper($operand) === 'TRUE') { - $result = (bool) $fieldValue; + $result = (bool)$fieldValue; } else { $result = !$fieldValue; } @@ -245,7 +245,7 @@ class ElementConditionMatcher { * @return bool */ protected function matchHideForNonAdminsCondition() { - return (bool) $this->getBackendUser()->isAdmin(); + return (bool)$this->getBackendUser()->isAdmin(); } /** diff --git a/typo3/sysext/backend/Classes/Form/FormEngine.php b/typo3/sysext/backend/Classes/Form/FormEngine.php index 7638946f37349a88e7eeb98479ccfc26c31d8060..c9c5dd1fc50f88c9c01866bb75a3ebf77129d906 100644 --- a/typo3/sysext/backend/Classes/Form/FormEngine.php +++ b/typo3/sysext/backend/Classes/Form/FormEngine.php @@ -1786,7 +1786,7 @@ class FormEngine { $typeNum = $GLOBALS['TCA'][$table]['types']['0'] ? 0 : 1; } // Force to string. Necessary for eg '-1' to be recognized as a type value. - $typeNum = (string) $typeNum; + $typeNum = (string)$typeNum; return $typeNum; } @@ -2589,7 +2589,7 @@ class FormEngine { } else { $icon = $iTitle; } - switch ((string) $wConf['type']) { + switch ((string)$wConf['type']) { case 'userFunc': case 'script': @@ -2676,7 +2676,7 @@ class FormEngine { $url = $this->backPath . $wScript . (strstr($wScript, '?') ? '' : '?'); // If "script" type, create the links around the icon: - if ((string) $wConf['type'] === 'script') { + if ((string)$wConf['type'] === 'script') { $aUrl = $url . GeneralUtility::implodeArrayForUrl('', array('P' => $params)); $outArr[] = '<a href="' . htmlspecialchars($aUrl) . '" onclick="this.blur(); return !TBE_EDITOR.isFormChanged();">' . $icon . '</a>'; } else { @@ -2686,7 +2686,7 @@ class FormEngine { $params['hmac'] = GeneralUtility::hmac($params['formName'] . $params['itemName'], 'wizard_js'); $params['fieldChangeFunc'] = $fieldChangeFunc; $params['fieldChangeFuncHash'] = GeneralUtility::hmac(serialize($fieldChangeFunc)); - switch ((string) $wConf['type']) { + switch ((string)$wConf['type']) { case 'popup': case 'colorbox': // Current form value is passed as P[currentValue]! @@ -2704,7 +2704,7 @@ class FormEngine { . 'vHWin.focus();return false;'; // Setting "colorBoxLinks" - user LATER to wrap around the color box as well: $colorBoxLinks = array('<a href="#" onclick="' . htmlspecialchars($aOnClick) . '">', '</a>'); - if ((string) $wConf['type'] == 'popup') { + if ((string)$wConf['type'] == 'popup') { $outArr[] = $colorBoxLinks[0] . $icon . $colorBoxLinks[1]; } break; @@ -2774,7 +2774,7 @@ class FormEngine { break; } // Color wizard colorbox: - if ((string) $wConf['type'] === 'colorbox') { + if ((string)$wConf['type'] === 'colorbox') { $dim = GeneralUtility::intExplode('x', $wConf['dim']); $dX = MathUtility::forceIntegerInRange($dim[0], 1, 200, 20); $dY = MathUtility::forceIntegerInRange($dim[1], 1, 200, 20); diff --git a/typo3/sysext/backend/Classes/Module/BaseScriptClass.php b/typo3/sysext/backend/Classes/Module/BaseScriptClass.php index 012b9f2c484973eee8a417ac0413b3b5a3d612c2..422cd01dc2e6017e60faf223b008bd7151141f6d 100644 --- a/typo3/sysext/backend/Classes/Module/BaseScriptClass.php +++ b/typo3/sysext/backend/Classes/Module/BaseScriptClass.php @@ -246,7 +246,7 @@ class BaseScriptClass { $mergeArray = $GLOBALS['TBE_MODULES_EXT'][$modName]['MOD_MENU'][$menuKey]; if (is_array($mergeArray)) { foreach ($mergeArray as $k => $v) { - if (((string) $v['ws'] === '' || $GLOBALS['BE_USER']->workspace === 0 && GeneralUtility::inList($v['ws'], 'online')) || $GLOBALS['BE_USER']->workspace === -1 && GeneralUtility::inList($v['ws'], 'offline') || $GLOBALS['BE_USER']->workspace > 0 && GeneralUtility::inList($v['ws'], 'custom')) { + if (((string)$v['ws'] === '' || $GLOBALS['BE_USER']->workspace === 0 && GeneralUtility::inList($v['ws'], 'online')) || $GLOBALS['BE_USER']->workspace === -1 && GeneralUtility::inList($v['ws'], 'offline') || $GLOBALS['BE_USER']->workspace > 0 && GeneralUtility::inList($v['ws'], 'custom')) { $menuArr[$k] = $GLOBALS['LANG']->sL($v['title']); } } diff --git a/typo3/sysext/backend/Classes/Module/ModuleSettings.php b/typo3/sysext/backend/Classes/Module/ModuleSettings.php index 8963a177509e0f56babed683a7c0f6639afdc25c..a95e394369319303319c34888f57493572b009d4 100644 --- a/typo3/sysext/backend/Classes/Module/ModuleSettings.php +++ b/typo3/sysext/backend/Classes/Module/ModuleSettings.php @@ -249,7 +249,7 @@ class ModuleSettings { } $storageArr = array( 'title' => $data['title'], - 'desc' => (string) $data['desc'], + 'desc' => (string)$data['desc'], 'data' => $storageData, 'user' => NULL, 'tstamp' => $GLOBALS['EXEC_TIME'] diff --git a/typo3/sysext/backend/Classes/RecordList/AbstractRecordList.php b/typo3/sysext/backend/Classes/RecordList/AbstractRecordList.php index 1a4d8e41fc808e1dfb1f81266becf92aee1c97f3..4f34d1138bf766adfebd222334dac00d75907011 100644 --- a/typo3/sysext/backend/Classes/RecordList/AbstractRecordList.php +++ b/typo3/sysext/backend/Classes/RecordList/AbstractRecordList.php @@ -185,7 +185,7 @@ abstract class AbstractRecordList { * @param string $icon Is the <img>+<a> of the record. If not supplied the first 'join'-icon will be a 'line' instead * @param array $data Is the dataarray, record with the fields. Notice: These fields are (currently) NOT htmlspecialchar'ed before being wrapped in <td>-tags * @param string $tdParams Is insert in the <td>-tags. Must carry a ' ' as first character - * @param int OBSOLETE - NOT USED ANYMORE. $lMargin is the leftMargin (integer) + * @param int OBSOLETE - NOT USED ANYMORE. $lMargin is the leftMargin (int) * @param string $altLine Is the HTML <img>-tag for an alternative 'gfx/ol/line.gif'-icon (used in the top) * @return string HTML content for the table row */ diff --git a/typo3/sysext/backend/Classes/Sprite/AbstractSpriteHandler.php b/typo3/sysext/backend/Classes/Sprite/AbstractSpriteHandler.php index 051a0dfd019ac6795946ae06bf937d7ca44193d8..515c701b42453540c635799258c03814e98c55b4 100644 --- a/typo3/sysext/backend/Classes/Sprite/AbstractSpriteHandler.php +++ b/typo3/sysext/backend/Classes/Sprite/AbstractSpriteHandler.php @@ -71,7 +71,7 @@ abstract class AbstractSpriteHandler implements \TYPO3\CMS\Backend\Sprite\Sprite // Saves which CSS Files are currently "allowed to be in place" $allowedCssFilesinTempDir = array(basename($this->cssTcaFile)); // Process every registeres file - foreach ((array) $GLOBALS['TBE_STYLES']['spritemanager']['cssFiles'] as $file) { + foreach ((array)$GLOBALS['TBE_STYLES']['spritemanager']['cssFiles'] as $file) { $fileName = basename($file); // File should be present $allowedCssFilesinTempDir[] = $fileName; diff --git a/typo3/sysext/backend/Classes/Sprite/SimpleSpriteHandler.php b/typo3/sysext/backend/Classes/Sprite/SimpleSpriteHandler.php index d774c0b0f6b072fff8e880ab343042dbb6a96dd2..6474f24d55376e686c15298695c6f66d2c3fb191 100644 --- a/typo3/sysext/backend/Classes/Sprite/SimpleSpriteHandler.php +++ b/typo3/sysext/backend/Classes/Sprite/SimpleSpriteHandler.php @@ -64,7 +64,7 @@ class SimpleSpriteHandler extends \TYPO3\CMS\Backend\Sprite\AbstractSpriteHandle // Backpath from the stylesheet file ($cssTcaFile) to PATH_site dir // in order to set the background-image URL paths correct $iconPath = '../../' . TYPO3_mainDir; - $iconsToProcess = array_merge((array) $GLOBALS['TBE_STYLES']['spritemanager']['singleIcons'], $this->collectTcaSpriteIcons()); + $iconsToProcess = array_merge((array)$GLOBALS['TBE_STYLES']['spritemanager']['singleIcons'], $this->collectTcaSpriteIcons()); foreach ($iconsToProcess as $iconName => $iconFile) { $css = str_replace('###NAME###', str_replace(array('extensions-', 'tcarecords-'), array('', ''), $iconName), $this->styleSheetTemplateExtIcons); $css = str_replace('###IMAGE###', \TYPO3\CMS\Core\Utility\GeneralUtility::resolveBackPath($iconPath . $iconFile), $css); diff --git a/typo3/sysext/backend/Classes/Sprite/SpriteBuildingHandler.php b/typo3/sysext/backend/Classes/Sprite/SpriteBuildingHandler.php index 37bd6acf312b5ff1be902223bcdc91922e5f90d2..0077c30dfbb2c0a6247f869ec17c5392f8bd6c9f 100644 --- a/typo3/sysext/backend/Classes/Sprite/SpriteBuildingHandler.php +++ b/typo3/sysext/backend/Classes/Sprite/SpriteBuildingHandler.php @@ -41,7 +41,7 @@ class SpriteBuildingHandler extends AbstractSpriteHandler { ->setIncludeTimestampInCSS(TRUE) ->setSpriteFolder(SpriteManager::$tempPath) ->setCSSFolder(SpriteManager::$tempPath); - $iconsToProcess = array_merge((array) $GLOBALS['TBE_STYLES']['spritemanager']['singleIcons'], $this->collectTcaSpriteIcons()); + $iconsToProcess = array_merge((array)$GLOBALS['TBE_STYLES']['spritemanager']['singleIcons'], $this->collectTcaSpriteIcons()); foreach ($iconsToProcess as $iconName => $iconFile) { $iconsToProcess[$iconName] = GeneralUtility::resolveBackPath('typo3/' . $iconFile); } diff --git a/typo3/sysext/backend/Classes/Sprite/SpriteManager.php b/typo3/sysext/backend/Classes/Sprite/SpriteManager.php index 6e249d471145fc8e8e8b4939fa31a63ae756d4db..455eb2b87648ec46d425ce6b0d0acd0f23dee1c1 100644 --- a/typo3/sysext/backend/Classes/Sprite/SpriteManager.php +++ b/typo3/sysext/backend/Classes/Sprite/SpriteManager.php @@ -92,7 +92,7 @@ class SpriteManager { // Generate CSS and TCA files, build icon set register $handler->generate(); // Get all icons registered from skins, merge with core icon list - $availableSkinIcons = (array) $GLOBALS['TBE_STYLES']['spriteIconApi']['coreSpriteImageNames']; + $availableSkinIcons = (array)$GLOBALS['TBE_STYLES']['spriteIconApi']['coreSpriteImageNames']; if (isset($GLOBALS['TBE_STYLES']['skins']) && is_array($GLOBALS['TBE_STYLES']['skins'])) { foreach ($GLOBALS['TBE_STYLES']['skins'] as $skinData) { $availableSkinIcons = array_merge($availableSkinIcons, (array)$skinData['availableSpriteIcons']); @@ -100,7 +100,7 @@ class SpriteManager { } // Merge icon names provided by the skin, with // registered "complete sprites" and the handler class - $iconNames = array_merge($availableSkinIcons, (array) $GLOBALS['TBE_STYLES']['spritemanager']['spriteIconsAvailable'], $handler->getAvailableIconNames()); + $iconNames = array_merge($availableSkinIcons, (array)$GLOBALS['TBE_STYLES']['spritemanager']['spriteIconsAvailable'], $handler->getAvailableIconNames()); $GLOBALS['TBE_STYLES']['spriteIconApi']['iconsAvailable'] = $iconNames; $cacheFileContent = '$GLOBALS[\'TBE_STYLES\'][\'spriteIconApi\'][\'iconsAvailable\'] = '; @@ -134,7 +134,7 @@ class SpriteManager { * @return void */ static public function addIconSprite(array $icons, $styleSheetFile = '') { - $GLOBALS['TBE_STYLES']['spritemanager']['spriteIconsAvailable'] = array_merge((array) $GLOBALS['TBE_STYLES']['spritemanager']['spriteIconsAvailable'], $icons); + $GLOBALS['TBE_STYLES']['spritemanager']['spriteIconsAvailable'] = array_merge((array)$GLOBALS['TBE_STYLES']['spritemanager']['spriteIconsAvailable'], $icons); if ($styleSheetFile !== '') { $GLOBALS['TBE_STYLES']['spritemanager']['cssFiles'][] = $styleSheetFile; } diff --git a/typo3/sysext/backend/Classes/Template/DocumentTemplate.php b/typo3/sysext/backend/Classes/Template/DocumentTemplate.php index 2dcc4dd2c55ac2d51770cb9b052aba860c8091a3..0fb0cee50da5603a7224a2b493d6143c96d7e438 100644 --- a/typo3/sysext/backend/Classes/Template/DocumentTemplate.php +++ b/typo3/sysext/backend/Classes/Template/DocumentTemplate.php @@ -347,7 +347,7 @@ function jumpToUrl(URL) { // Initializes the page rendering object: $this->getPageRenderer(); // Setting default scriptID: - if (($temp_M = (string) GeneralUtility::_GET('M')) && $GLOBALS['TBE_MODULES']['_PATHS'][$temp_M]) { + if (($temp_M = (string)GeneralUtility::_GET('M')) && $GLOBALS['TBE_MODULES']['_PATHS'][$temp_M]) { $this->scriptID = preg_replace('/^.*\\/(sysext|ext)\\//', 'ext/', $GLOBALS['TBE_MODULES']['_PATHS'][$temp_M] . 'index.php'); } else { $this->scriptID = preg_replace('/^.*\\/(sysext|ext)\\//', 'ext/', \TYPO3\CMS\Core\Utility\PathUtility::stripPathSitePrefix(PATH_thisScript)); @@ -622,7 +622,7 @@ function jumpToUrl(URL) { */ public function makeShortcutUrl($gvList, $setList) { $GET = GeneralUtility::_GET(); - $storeArray = array_merge(GeneralUtility::compileSelectedGetVarsFromArray($gvList, $GET), array('SET' => GeneralUtility::compileSelectedGetVarsFromArray($setList, (array) $GLOBALS['SOBE']->MOD_SETTINGS))); + $storeArray = array_merge(GeneralUtility::compileSelectedGetVarsFromArray($gvList, $GET), array('SET' => GeneralUtility::compileSelectedGetVarsFromArray($setList, (array)$GLOBALS['SOBE']->MOD_SETTINGS))); $storeUrl = GeneralUtility::implodeArrayForUrl('', $storeArray); return $storeUrl; } @@ -725,7 +725,7 @@ function jumpToUrl(URL) { * @return void */ public function useCompatibilityTag($useCompatibilityTag = TRUE) { - $this->useCompatibilityTag = (bool) $useCompatibilityTag; + $this->useCompatibilityTag = (bool)$useCompatibilityTag; } /***************************************** diff --git a/typo3/sysext/backend/Classes/Toolbar/ClearCacheToolbarItem.php b/typo3/sysext/backend/Classes/Toolbar/ClearCacheToolbarItem.php index 2da35a45c276fcbfe708a80e5e9c70c90caa9120..1613c0c904cf8b6c5838c2124b1ae904d1bb1d40 100644 --- a/typo3/sysext/backend/Classes/Toolbar/ClearCacheToolbarItem.php +++ b/typo3/sysext/backend/Classes/Toolbar/ClearCacheToolbarItem.php @@ -89,7 +89,7 @@ class ClearCacheToolbarItem implements ToolbarItemHookInterface { // or if the system runs in development mode // or if $GLOBALS['TYPO3_CONF_VARS']['SYS']['clearCacheSystem'] is set (only for admins) if ($backendUser->getTSConfigVal('options.clearCache.system') || GeneralUtility::getApplicationContext()->isDevelopment() - || ((bool) $GLOBALS['TYPO3_CONF_VARS']['SYS']['clearCacheSystem'] === TRUE && $backendUser->isAdmin())) { + || ((bool)$GLOBALS['TYPO3_CONF_VARS']['SYS']['clearCacheSystem'] === TRUE && $backendUser->isAdmin())) { $this->cacheActions[] = array( 'id' => 'system', 'title' => $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:flushSystemCachesTitle', TRUE), diff --git a/typo3/sysext/backend/Classes/Toolbar/ShortcutToolbarItem.php b/typo3/sysext/backend/Classes/Toolbar/ShortcutToolbarItem.php index 45bc753589087e04bb7e966b7a2321e72833cb18..5abe600212f7f50d7bd5d7b80991f218b89cda38 100644 --- a/typo3/sysext/backend/Classes/Toolbar/ShortcutToolbarItem.php +++ b/typo3/sysext/backend/Classes/Toolbar/ShortcutToolbarItem.php @@ -102,7 +102,7 @@ class ShortcutToolbarItem implements \TYPO3\CMS\Backend\Toolbar\ToolbarItemHookI * @return bool TRUE if user has access, FALSE if not */ public function checkAccess() { - return (bool) $GLOBALS['BE_USER']->getTSConfigVal('options.enableBookmarks'); + return (bool)$GLOBALS['BE_USER']->getTSConfigVal('options.enableBookmarks'); } /** diff --git a/typo3/sysext/backend/Classes/Tree/ExtDirectNode.php b/typo3/sysext/backend/Classes/Tree/ExtDirectNode.php index 17198d250abab8f26456bc28ee4ec5655e686c6a..07cae02ab5434b695e1003b7141312af890073f0 100644 --- a/typo3/sysext/backend/Classes/Tree/ExtDirectNode.php +++ b/typo3/sysext/backend/Classes/Tree/ExtDirectNode.php @@ -469,7 +469,7 @@ class ExtDirectNode extends \TYPO3\CMS\Backend\Tree\TreeNode { * @return void */ public function setRecord($record) { - $this->record = (array) $record; + $this->record = (array)$record; } /** @@ -488,7 +488,7 @@ class ExtDirectNode extends \TYPO3\CMS\Backend\Tree\TreeNode { * @return void */ public function setContextInfo($contextInfo) { - $this->contextInfo = (array) $contextInfo; + $this->contextInfo = (array)$contextInfo; } /** @@ -497,7 +497,7 @@ class ExtDirectNode extends \TYPO3\CMS\Backend\Tree\TreeNode { * @return array */ public function getContextInfo() { - return (array) $this->contextInfo; + return (array)$this->contextInfo; } /** diff --git a/typo3/sysext/backend/Classes/Tree/Pagetree/ExtdirectTreeCommands.php b/typo3/sysext/backend/Classes/Tree/Pagetree/ExtdirectTreeCommands.php index 1406d6b0d9978cd1425572c011eeaab1c15c7998..401e7baee0806422341b3f864ea6ae411f3da33d 100644 --- a/typo3/sysext/backend/Classes/Tree/Pagetree/ExtdirectTreeCommands.php +++ b/typo3/sysext/backend/Classes/Tree/Pagetree/ExtdirectTreeCommands.php @@ -32,7 +32,7 @@ class ExtdirectTreeCommands { */ public function visiblyNode($nodeData) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); try { Commands::visiblyNode($node); $newNode = Commands::getNode($node->getId()); @@ -55,7 +55,7 @@ class ExtdirectTreeCommands { */ public function disableNode($nodeData) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); try { Commands::disableNode($node); $newNode = Commands::getNode($node->getId()); @@ -78,7 +78,7 @@ class ExtdirectTreeCommands { */ public function deleteNode($nodeData) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); try { Commands::deleteNode($node); $returnValue = array(); @@ -107,7 +107,7 @@ class ExtdirectTreeCommands { */ public function restoreNode($nodeData, $destination) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); try { Commands::restoreNode($node, $destination); $newNode = Commands::getNode($node->getId()); @@ -134,7 +134,7 @@ class ExtdirectTreeCommands { return array(); } /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); try { Commands::updateNodeLabel($node, $updatedLabel); $shortendedText = GeneralUtility::fixed_lgd_cs($updatedLabel, (int)$GLOBALS['BE_USER']->uc['titleLen']); @@ -159,7 +159,7 @@ class ExtdirectTreeCommands { */ static public function setTemporaryMountPoint($nodeData) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); $GLOBALS['BE_USER']->uc['pageTree_temporaryMountPoint'] = $node->getId(); $GLOBALS['BE_USER']->writeUC($GLOBALS['BE_USER']->uc); return Commands::getMountPointPath(); @@ -174,7 +174,7 @@ class ExtdirectTreeCommands { */ public function moveNodeToFirstChildOfDestination($nodeData, $destination) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); try { Commands::moveNode($node, $destination); $newNode = Commands::getNode($node->getId(), FALSE); @@ -198,7 +198,7 @@ class ExtdirectTreeCommands { */ public function moveNodeAfterDestination($nodeData, $destination) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); try { Commands::moveNode($node, -$destination); $newNode = Commands::getNode($node->getId(), FALSE); @@ -223,7 +223,7 @@ class ExtdirectTreeCommands { */ public function copyNodeToFirstChildOfDestination($nodeData, $destination) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); /** @var $dataProvider \TYPO3\CMS\Backend\Tree\Pagetree\DataProvider */ $dataProvider = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\DataProvider'); try { @@ -250,7 +250,7 @@ class ExtdirectTreeCommands { */ public function copyNodeAfterDestination($nodeData, $destination) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); /** @var $dataProvider \TYPO3\CMS\Backend\Tree\Pagetree\DataProvider */ $dataProvider = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\DataProvider'); try { @@ -276,7 +276,7 @@ class ExtdirectTreeCommands { */ public function insertNodeToFirstChildOfDestination($parentNodeData, $pageType) { /** @var $parentNode \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $parentNode = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $parentNodeData); + $parentNode = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$parentNodeData); try { $newPageId = Commands::createNode($parentNode, $parentNode->getId(), $pageType); $returnValue = Commands::getNode($newPageId)->toArray(); @@ -299,7 +299,7 @@ class ExtdirectTreeCommands { */ public function insertNodeAfterDestination($parentNodeData, $destination, $pageType) { /** @var $parentNode \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $parentNode = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $parentNodeData); + $parentNode = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$parentNodeData); try { $newPageId = Commands::createNode($parentNode, -$destination, $pageType); $returnValue = Commands::getNode($newPageId)->toArray(); @@ -320,7 +320,7 @@ class ExtdirectTreeCommands { */ static public function getViewLink($nodeData) { /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); $javascriptLink = BackendUtility::viewOnClick($node->getId()); preg_match('/window\\.open\\(\'([^\']+)\'/i', $javascriptLink, $match); return $match[1]; @@ -368,7 +368,7 @@ class ExtdirectTreeCommands { } } $userSettings->set('BackendComponents.States.' . $stateId, $state); - return (array) $state->stateHash; + return (array)$state->stateHash; } } diff --git a/typo3/sysext/backend/Classes/Tree/Pagetree/ExtdirectTreeDataProvider.php b/typo3/sysext/backend/Classes/Tree/Pagetree/ExtdirectTreeDataProvider.php index 0c013d8b573df5ec4d4fabab3780ca9dde8b350d..fc60c58c66c9dd3cf8250f2ed7be6aef0ada0e44 100644 --- a/typo3/sysext/backend/Classes/Tree/Pagetree/ExtdirectTreeDataProvider.php +++ b/typo3/sysext/backend/Classes/Tree/Pagetree/ExtdirectTreeDataProvider.php @@ -63,7 +63,7 @@ class ExtdirectTreeDataProvider extends \TYPO3\CMS\Backend\Tree\AbstractExtJsTre public function getNextTreeLevel($nodeId, $nodeData) { $this->initDataProvider(); /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); if ($nodeId === 'root') { $nodeCollection = $this->dataProvider->getTreeMounts(); } else { @@ -85,7 +85,7 @@ class ExtdirectTreeDataProvider extends \TYPO3\CMS\Backend\Tree\AbstractExtJsTre return array(); } /** @var $node \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */ - $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array) $nodeData); + $node = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Tree\\Pagetree\\PagetreeNode', (array)$nodeData); $this->initDataProvider(); if ($nodeId === 'root') { $nodeCollection = $this->dataProvider->getTreeMounts($searchFilter); diff --git a/typo3/sysext/backend/Classes/Utility/BackendUtility.php b/typo3/sysext/backend/Classes/Utility/BackendUtility.php index be2da57cf1e610d5f5fc331279e2b521c290dd5e..3f10d5b1120042ce58b019e0845c99d92be9f6f8 100644 --- a/typo3/sysext/backend/Classes/Utility/BackendUtility.php +++ b/typo3/sysext/backend/Classes/Utility/BackendUtility.php @@ -217,12 +217,12 @@ class BackendUtility { */ static public function getSQLselectableList($in_list, $tablename, $default_tablename) { $list = array(); - if ((string) trim($in_list) != '') { + if ((string)trim($in_list) != '') { $tempItemArray = explode(',', trim($in_list)); foreach ($tempItemArray as $key => $val) { $val = strrev($val); $parts = explode('_', $val, 2); - if ((string) trim($parts[0]) != '') { + if ((string)trim($parts[0]) != '') { $theID = (int)strrev($parts[0]); $theTable = trim($parts[1]) ? strrev(trim($parts[1])) : $default_tablename; if ($theTable == $tablename) { @@ -572,7 +572,7 @@ class BackendUtility { if ((string)$iVal[1] !== '') { // Find iMode $iMode = ''; - switch ((string) $fCfg['authMode']) { + switch ((string)$fCfg['authMode']) { case 'explicitAllow': $iMode = 'ALLOW'; break; @@ -821,7 +821,7 @@ class BackendUtility { $typeNum = $GLOBALS['TCA'][$table]['types']['0'] ? 0 : 1; } // Force to string. Necessary for eg '-1' to be recognized as a type value. - $typeNum = (string) $typeNum; + $typeNum = (string)$typeNum; return $typeNum; } @@ -2096,7 +2096,7 @@ class BackendUtility { $l = ''; $db = static::getDatabaseConnection(); $lang = static::getLanguageService(); - switch ((string) $theColConf['type']) { + switch ((string)$theColConf['type']) { case 'radio': $l = self::getLabelFromItemlist($table, $col, $value); $l = $lang->sL($l); @@ -2747,7 +2747,7 @@ class BackendUtility { $urlParts = parse_url($domain); /** @var PageRepository $sysPage */ $sysPage = GeneralUtility::makeInstance('TYPO3\\CMS\\Frontend\\Page\\PageRepository'); - $page = (array) $sysPage->getPage($pageId); + $page = (array)$sysPage->getPage($pageId); $protocol = 'http'; if ($page['url_scheme'] == HttpUtility::SCHEME_HTTPS || $page['url_scheme'] == 0 && GeneralUtility::getIndpEnv('TYPO3_SSL')) { $protocol = 'https'; @@ -3052,14 +3052,14 @@ class BackendUtility { if (is_array($var) && (!$dontValidateList || !GeneralUtility::inList($dontValidateList, $key))) { // If the setting is an array or not present in the menu-array, MOD_MENU, then the default value is inserted. if (is_array($settings[$key]) || !isset($MOD_MENU[$key][$settings[$key]])) { - $settings[$key] = (string) key($var); + $settings[$key] = (string)key($var); $changed = 1; } } // Sets default values (only strings/checkboxes, not menus) if ($setDefaultList && !is_array($var)) { if (GeneralUtility::inList($setDefaultList, $key) && !isset($settings[$key])) { - $settings[$key] = (string) $var; + $settings[$key] = (string)$var; } } } diff --git a/typo3/sysext/backend/Classes/Utility/IconUtility.php b/typo3/sysext/backend/Classes/Utility/IconUtility.php index 0eeb57420c06b5742bb54740113736e42734ff40..e0100bfc82ba785e7fefde102ee98ea5380fa55d 100644 --- a/typo3/sysext/backend/Classes/Utility/IconUtility.php +++ b/typo3/sysext/backend/Classes/Utility/IconUtility.php @@ -608,7 +608,7 @@ class IconUtility { } $availableIcons = isset($GLOBALS['TBE_STYLES']['spriteIconApi']['iconsAvailable']) - ? (array) $GLOBALS['TBE_STYLES']['spriteIconApi']['iconsAvailable'] + ? (array)$GLOBALS['TBE_STYLES']['spriteIconApi']['iconsAvailable'] : array(); if ($iconName !== 'empty-empty' && !in_array($iconName, $availableIcons, TRUE)) { $iconName = 'status-status-icon-missing'; diff --git a/typo3/sysext/backend/Classes/View/BackendLayout/DefaultDataProvider.php b/typo3/sysext/backend/Classes/View/BackendLayout/DefaultDataProvider.php index c0f8f985ae388b300ae01522f1393de56ade7491..d60d18c6a49d0bd3262f74a22c0eae270c5316c1 100644 --- a/typo3/sysext/backend/Classes/View/BackendLayout/DefaultDataProvider.php +++ b/typo3/sysext/backend/Classes/View/BackendLayout/DefaultDataProvider.php @@ -56,7 +56,7 @@ class DefaultDataProvider implements DataProviderInterface { public function getBackendLayout($identifier, $pageId) { $backendLayout = NULL; - if ((string) $identifier === 'default') { + if ((string)$identifier === 'default') { return $this->createDefaultBackendLayout(); } diff --git a/typo3/sysext/backend/Classes/View/BackendLayoutView.php b/typo3/sysext/backend/Classes/View/BackendLayoutView.php index 7d7f076fc2f85bd3edba689532e260dca4f6a1a5..17db832e80d5ae03984ca39e995575f6b97b34be 100644 --- a/typo3/sysext/backend/Classes/View/BackendLayoutView.php +++ b/typo3/sysext/backend/Classes/View/BackendLayoutView.php @@ -64,7 +64,7 @@ class BackendLayoutView implements \TYPO3\CMS\Core\SingletonInterface { ); if (!empty($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['BackendLayoutDataProvider'])) { - $dataProviders = (array) $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['BackendLayoutDataProvider']; + $dataProviders = (array)$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['BackendLayoutDataProvider']; foreach ($dataProviders as $identifier => $className) { $dataProviderCollection->add($identifier, $className); } @@ -96,7 +96,7 @@ class BackendLayoutView implements \TYPO3\CMS\Core\SingletonInterface { */ public function addBackendLayoutItems(array $parameters) { $pageId = $this->determinePageId($parameters['table'], $parameters['row']); - $pageTsConfig = (array) BackendUtility::getPagesTSconfig($pageId); + $pageTsConfig = (array)BackendUtility::getPagesTSconfig($pageId); $identifiersToBeExcluded = $this->getIdentifiersToBeExcluded($pageTsConfig); $dataProviderContext = $this->createDataProviderContext() @@ -170,7 +170,7 @@ class BackendLayoutView implements \TYPO3\CMS\Core\SingletonInterface { public function getSelectedCombinedIdentifier($pageId) { if (!isset($this->selectedCombinedIdentifier[$pageId])) { $page = $this->getPage($pageId); - $this->selectedCombinedIdentifier[$pageId] = (string) $page['backend_layout']; + $this->selectedCombinedIdentifier[$pageId] = (string)$page['backend_layout']; if ($this->selectedCombinedIdentifier[$pageId] === '-1') { // If it is set to "none" - don't use any @@ -183,7 +183,7 @@ class BackendLayoutView implements \TYPO3\CMS\Core\SingletonInterface { array_shift($rootLine); array_pop($rootLine); foreach ($rootLine as $rootLinePage) { - $this->selectedCombinedIdentifier[$pageId] = (string) $rootLinePage['backend_layout_next_level']; + $this->selectedCombinedIdentifier[$pageId] = (string)$rootLinePage['backend_layout_next_level']; if ($this->selectedCombinedIdentifier[$pageId] === '-1') { // If layout for "next level" is set to "none" - don't use any and stop searching $this->selectedCombinedIdentifier[$pageId] = FALSE; diff --git a/typo3/sysext/backend/Classes/View/PageLayoutView.php b/typo3/sysext/backend/Classes/View/PageLayoutView.php index b9b137c25da78e0e77e487c1286aa74f027e03e0..01f18f2634215dfb9955af09bce9bcd8a5e5c076 100644 --- a/typo3/sysext/backend/Classes/View/PageLayoutView.php +++ b/typo3/sysext/backend/Classes/View/PageLayoutView.php @@ -476,7 +476,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe $editUidList = ''; $rowArr = $contentRecordsPerColumn[$key]; $this->generateTtContentDataArray($rowArr); - foreach ((array) $rowArr as $rKey => $row) { + foreach ((array)$rowArr as $rKey => $row) { if ($this->tt_contentConfig['languageMode']) { $languageColumn[$key][$lP] = $head[$key] . $content[$key]; if (!$this->defLangBinding) { diff --git a/typo3/sysext/belog/Classes/Domain/Model/Constraint.php b/typo3/sysext/belog/Classes/Domain/Model/Constraint.php index 92dab95baa06f43ba8c34052337e5a71ede49b2c..164853c24800b04487bf326eb20f3fa28d95a7b2 100644 --- a/typo3/sysext/belog/Classes/Domain/Model/Constraint.php +++ b/typo3/sysext/belog/Classes/Domain/Model/Constraint.php @@ -230,7 +230,7 @@ class Constraint extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity { * @return bool */ public function getGroupByPage() { - return (bool) $this->groupByPage; + return (bool)$this->groupByPage; } /** @@ -325,7 +325,7 @@ class Constraint extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity { * @return bool */ public function getIsInPageContext() { - return (bool) $this->isInPageContext; + return (bool)$this->isInPageContext; } /** diff --git a/typo3/sysext/core/Classes/Authentication/AbstractUserAuthentication.php b/typo3/sysext/core/Classes/Authentication/AbstractUserAuthentication.php index a20a838809312024d7a53d2cbb05748ba960c5d0..409c4eaa018468d194a846ec2c450d5bfc4db8b5 100644 --- a/typo3/sysext/core/Classes/Authentication/AbstractUserAuthentication.php +++ b/typo3/sysext/core/Classes/Authentication/AbstractUserAuthentication.php @@ -483,9 +483,9 @@ abstract class AbstractUserAuthentication { // If the cookie lifetime is set, use it: $cookieExpire = $isRefreshTimeBasedCookie ? $GLOBALS['EXEC_TIME'] + $this->lifetime : 0; // Use the secure option when the current request is served by a secure connection: - $cookieSecure = (bool) $settings['cookieSecure'] && GeneralUtility::getIndpEnv('TYPO3_SSL'); + $cookieSecure = (bool)$settings['cookieSecure'] && GeneralUtility::getIndpEnv('TYPO3_SSL'); // Deliver cookies only via HTTP and prevent possible XSS by JavaScript: - $cookieHttpOnly = (bool) $settings['cookieHttpOnly']; + $cookieHttpOnly = (bool)$settings['cookieHttpOnly']; // Do not set cookie if cookieSecure is set to "1" (force HTTPS) and no secure channel is used: if ((int)$settings['cookieSecure'] !== 1 || GeneralUtility::getIndpEnv('TYPO3_SSL')) { setcookie($this->name, $this->id, $cookieExpire, $cookiePath, $cookieDomain, $cookieSecure, $cookieHttpOnly); @@ -855,7 +855,7 @@ abstract class AbstractUserAuthentication { ); // Re-create session entry $insertFields = $this->getNewSessionRecord($tempuser); - $inserted = (boolean) $this->db->exec_INSERTquery($this->session_table, $insertFields); + $inserted = (bool)$this->db->exec_INSERTquery($this->session_table, $insertFields); if (!$inserted) { $message = 'Session data could not be written to DB. Error: ' . $this->db->sql_error(); GeneralUtility::sysLog($message, 'Core', GeneralUtility::SYSLOG_SEVERITY_WARNING); diff --git a/typo3/sysext/core/Classes/Authentication/BackendUserAuthentication.php b/typo3/sysext/core/Classes/Authentication/BackendUserAuthentication.php index c61dce706599530133b376b4257902da238bbb72..608988c307b2d8bf0f9482d202a69dac828baf5d 100644 --- a/typo3/sysext/core/Classes/Authentication/BackendUserAuthentication.php +++ b/typo3/sysext/core/Classes/Authentication/BackendUserAuthentication.php @@ -629,7 +629,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU $testValue = $table . ':' . $field . ':' . $value; $out = TRUE; // Checking value: - switch ((string) $authMode) { + switch ((string)$authMode) { case 'explicitAllow': if (!GeneralUtility::inList($this->groupData['explicit_allowdeny'], ($testValue . ':ALLOW'))) { $out = FALSE; @@ -725,7 +725,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU * It only deal with record internals; If any values in the record fields disallows it. * For instance languages settings, authMode selector boxes are evaluated (and maybe more in the future). * It will check for workspace dependent access. - * The function takes an ID (integer) or row (array) as second argument. + * The function takes an ID (int) or row (array) as second argument. * * @param string $table Table name * @param mixed $idOrRow If integer, then this is the ID of the record. If Array this just represents fields in the record. @@ -1210,7 +1210,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU * @return array */ public function returnWebmounts() { - return (string) $this->groupData['webmounts'] != '' ? explode(',', $this->groupData['webmounts']) : array(); + return (string)$this->groupData['webmounts'] != '' ? explode(',', $this->groupData['webmounts']) : array(); } /** @@ -1465,7 +1465,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU * @access private */ public function setCachedList($cList) { - if ((string) $cList != (string) $this->user['usergroup_cached_list']) { + if ((string)$cList != (string)$this->user['usergroup_cached_list']) { $this->db->exec_UPDATEquery('be_users', 'uid=' . (int)$this->user['uid'], array('usergroup_cached_list' => $cList)); } } @@ -1762,7 +1762,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU array_walk( $permissionsTsConfig, function($value, $permission) use (&$filePermissions) { - $filePermissions[$permission] = (bool) $value; + $filePermissions[$permission] = (bool)$value; } ); } @@ -1790,7 +1790,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU array_walk( $storageFilePermissions, function($value, $permission) use (&$finalUserPermissions) { - $finalUserPermissions[$permission] = (bool) $value; + $finalUserPermissions[$permission] = (bool)$value; } ); } @@ -1935,7 +1935,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU $retVal = FALSE; // If not array, look up workspace record: if (!is_array($wsRec)) { - switch ((string) $wsRec) { + switch ((string)$wsRec) { case '0': $wsRec = array('uid' => $wsRec); break; @@ -1955,7 +1955,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU if ($this->isAdmin()) { return array_merge($wsRec, array('_ACCESS' => 'admin')); } else { - switch ((string) $wsRec['uid']) { + switch ((string)$wsRec['uid']) { case '0': $retVal = $this->groupData['workspace_perms'] & 1 ? array_merge($wsRec, array('_ACCESS' => 'online')) @@ -2134,7 +2134,7 @@ class BackendUserAuthentication extends \TYPO3\CMS\Core\Authentication\AbstractU 'log_data' => serialize($data), 'tablename' => $tablename, 'recuid' => (int)$recuid, - 'IP' => (string) GeneralUtility::getIndpEnv('REMOTE_ADDR'), + 'IP' => (string)GeneralUtility::getIndpEnv('REMOTE_ADDR'), 'tstamp' => $GLOBALS['EXEC_TIME'], 'event_pid' => (int)$event_pid, 'NEWid' => $NEWid, @@ -2365,7 +2365,7 @@ This is a dump of the failures: * @internal */ public function overrideUC() { - $this->uc = array_merge((array) $this->uc, (array) $this->getTSConfigProp('setup.override')); + $this->uc = array_merge((array)$this->uc, (array)$this->getTSConfigProp('setup.override')); } /** diff --git a/typo3/sysext/core/Classes/Cache/Backend/ApcBackend.php b/typo3/sysext/core/Classes/Cache/Backend/ApcBackend.php index da38ec1537888a7d73b106621a20491f854cefe7..4251ff26c7bccc3fd1b2cb932e1d09bddb13bba3 100644 --- a/typo3/sysext/core/Classes/Cache/Backend/ApcBackend.php +++ b/typo3/sysext/core/Classes/Cache/Backend/ApcBackend.php @@ -201,7 +201,7 @@ class ApcBackend extends \TYPO3\CMS\Core\Cache\Backend\AbstractBackend implement if ($success === FALSE) { return array(); } else { - return (array) $identifiers; + return (array)$identifiers; } } @@ -215,7 +215,7 @@ class ApcBackend extends \TYPO3\CMS\Core\Cache\Backend\AbstractBackend implement protected function findTagsByIdentifier($identifier) { $success = FALSE; $tags = apc_fetch($this->getIdentifierPrefix() . 'ident_' . $identifier, $success); - return $success ? (array) $tags : array(); + return $success ? (array)$tags : array(); } /** diff --git a/typo3/sysext/core/Classes/Cache/Backend/MemcachedBackend.php b/typo3/sysext/core/Classes/Cache/Backend/MemcachedBackend.php index 0705e3d54340efdbd9c74f823a6ee58ab36e7e33..39eb7f5b8d3b74db4c26c719bd634322b9d0d0b6 100644 --- a/typo3/sysext/core/Classes/Cache/Backend/MemcachedBackend.php +++ b/typo3/sysext/core/Classes/Cache/Backend/MemcachedBackend.php @@ -273,7 +273,7 @@ class MemcachedBackend extends \TYPO3\CMS\Core\Cache\Backend\AbstractBackend imp public function findIdentifiersByTag($tag) { $identifiers = $this->memcache->get($this->identifierPrefix . 'tag_' . $tag); if ($identifiers !== FALSE) { - return (array) $identifiers; + return (array)$identifiers; } else { return array(); } @@ -380,7 +380,7 @@ class MemcachedBackend extends \TYPO3\CMS\Core\Cache\Backend\AbstractBackend imp */ protected function findTagsByIdentifier($identifier) { $tags = $this->memcache->get($this->identifierPrefix . 'ident_' . $identifier); - return $tags === FALSE ? array() : (array) $tags; + return $tags === FALSE ? array() : (array)$tags; } /** diff --git a/typo3/sysext/core/Classes/Cache/Backend/WincacheBackend.php b/typo3/sysext/core/Classes/Cache/Backend/WincacheBackend.php index ef152322930f26d3bff82bd1ba5df4e42c79da9a..989152961f777dcf59042d9f82ef29422f6b268a 100644 --- a/typo3/sysext/core/Classes/Cache/Backend/WincacheBackend.php +++ b/typo3/sysext/core/Classes/Cache/Backend/WincacheBackend.php @@ -136,7 +136,7 @@ class WincacheBackend extends \TYPO3\CMS\Core\Cache\Backend\AbstractBackend impl if ($success === FALSE) { return array(); } else { - return (array) $identifiers; + return (array)$identifiers; } } @@ -150,7 +150,7 @@ class WincacheBackend extends \TYPO3\CMS\Core\Cache\Backend\AbstractBackend impl protected function findTagsByIdentifier($identifier) { $success = FALSE; $tags = wincache_ucache_get($this->identifierPrefix . 'ident_' . $identifier, $success); - return $success ? (array) $tags : array(); + return $success ? (array)$tags : array(); } /** diff --git a/typo3/sysext/core/Classes/Configuration/TypoScript/ConditionMatching/AbstractConditionMatcher.php b/typo3/sysext/core/Classes/Configuration/TypoScript/ConditionMatching/AbstractConditionMatcher.php index 2508b7887c5d54359e2dd22ffa2de10a815df40d..eed10ae34abfb8085f007d5fa526f03d8a00b439 100644 --- a/typo3/sysext/core/Classes/Configuration/TypoScript/ConditionMatching/AbstractConditionMatcher.php +++ b/typo3/sysext/core/Classes/Configuration/TypoScript/ConditionMatching/AbstractConditionMatcher.php @@ -310,10 +310,10 @@ abstract class AbstractConditionMatcher { $value = trim($GLOBALS['TYPO3_CONF_VARS']['SYS']['devIPmask']); } - return (bool) GeneralUtility::cmpIP(GeneralUtility::getIndpEnv('REMOTE_ADDR'), $value); + return (bool)GeneralUtility::cmpIP(GeneralUtility::getIndpEnv('REMOTE_ADDR'), $value); break; case 'hostname': - return (bool) GeneralUtility::cmpFQDN(GeneralUtility::getIndpEnv('REMOTE_ADDR'), $value); + return (bool)GeneralUtility::cmpFQDN(GeneralUtility::getIndpEnv('REMOTE_ADDR'), $value); break; case 'hour': @@ -482,7 +482,7 @@ abstract class AbstractConditionMatcher { $splitAgain = explode('|', $vars[1], 2); $k = trim($splitAgain[0]); if ($k) { - switch ((string) trim($vars[0])) { + switch ((string)trim($vars[0])) { case 'GP': $value = GeneralUtility::_GP($k); break; diff --git a/typo3/sysext/core/Classes/Core/Bootstrap.php b/typo3/sysext/core/Classes/Core/Bootstrap.php index 23fc697ee3304e3a24515b2fa183c1ccafcbac3e..62a0567b3e8447b91baef1cddd702cbea6a755c4 100644 --- a/typo3/sysext/core/Classes/Core/Bootstrap.php +++ b/typo3/sysext/core/Classes/Core/Bootstrap.php @@ -257,7 +257,7 @@ class Bootstrap { public function initializeClassLoader() { $classLoader = new ClassLoader($this->applicationContext); $this->setEarlyInstance('TYPO3\\CMS\\Core\\Core\\ClassLoader', $classLoader); - $classLoader->setRuntimeClassLoadingInformationFromAutoloadRegistry((array) include __DIR__ . '/../../ext_autoload.php'); + $classLoader->setRuntimeClassLoadingInformationFromAutoloadRegistry((array)include __DIR__ . '/../../ext_autoload.php'); $classAliasMap = new ClassAliasMap(); $classAliasMap->injectClassLoader($classLoader); $this->setEarlyInstance('TYPO3\\CMS\\Core\\Core\\ClassAliasMap', $classAliasMap); diff --git a/typo3/sysext/core/Classes/DataHandling/DataHandler.php b/typo3/sysext/core/Classes/DataHandling/DataHandler.php index 82db7413ff9eb335f48acfdad0584a29364c2c7c..80ac506755707d56ab102272d619a115be54d701 100644 --- a/typo3/sysext/core/Classes/DataHandling/DataHandler.php +++ b/typo3/sysext/core/Classes/DataHandling/DataHandler.php @@ -1409,7 +1409,7 @@ class DataHandler { if (!$this->dontProcessTransformations) { if (isset($fieldArray[$vconf['field']])) { // Look for transformation flag: - switch ((string) $incomingFieldArray[('_TRANSFORM_' . $vconf['field'])]) { + switch ((string)$incomingFieldArray[('_TRANSFORM_' . $vconf['field'])]) { case 'RTE': $RTEsetup = $this->BE_USER->getTSConfig('RTE', BackendUtility::getPagesTSconfig($tscPID)); $thisConfig = BackendUtility::RTEsetup($RTEsetup['properties'], $table, $vconf['field'], $theTypeString); @@ -3953,7 +3953,7 @@ class DataHandler { * @param string $table Table name * @param int $uid Record uid (to be localized) * @param int $language Language ID (from sys_language table) - * @return mixed The uid (integer) of the new translated record or FALSE (boolean) if something went wrong + * @return mixed The uid (int) of the new translated record or FALSE (bool) if something went wrong */ public function localize($table, $uid, $language) { $newId = FALSE; @@ -4060,7 +4060,7 @@ class DataHandler { * * @param string $table The table of the localized parent record * @param int $id The uid of the localized parent record - * @param string $command Defines the type 'localize' or 'synchronize' (string) or a single uid to be localized (integer) + * @param string $command Defines the type 'localize' or 'synchronize' (string) or a single uid to be localized (int) * @return void */ protected function inlineLocalizeSynchronize($table, $id, $command) { @@ -7002,7 +7002,7 @@ class DataHandler { case 'temp_cached': case 'system': if ($this->admin || $this->BE_USER->getTSConfigVal('options.clearCache.system') - || ((bool) $GLOBALS['TYPO3_CONF_VARS']['SYS']['clearCacheSystem'] === TRUE && $this->admin)) { + || ((bool)$GLOBALS['TYPO3_CONF_VARS']['SYS']['clearCacheSystem'] === TRUE && $this->admin)) { $this->getCacheManager()->flushCachesInGroup('system'); } break; @@ -7264,7 +7264,7 @@ class DataHandler { * @return bool */ protected function isNestedElementCallRegistered($table, $id, $identifier) { - $nestedElementCalls = (array) $this->getMemoryCache()->get('nestedElementCalls'); + $nestedElementCalls = (array)$this->getMemoryCache()->get('nestedElementCalls'); return isset($nestedElementCalls[$identifier][$table][$id]); } @@ -7278,7 +7278,7 @@ class DataHandler { * @return void */ protected function registerNestedElementCall($table, $id, $identifier) { - $nestedElementCalls = (array) $this->getMemoryCache()->get('nestedElementCalls'); + $nestedElementCalls = (array)$this->getMemoryCache()->get('nestedElementCalls'); $nestedElementCalls[$identifier][$table][$id] = TRUE; $this->getMemoryCache()->set('nestedElementCalls', $nestedElementCalls); } @@ -7304,7 +7304,7 @@ class DataHandler { * @see versionizeRecord */ protected function isElementToBeDeleted($table, $id) { - $elementsToBeDeleted = (array) $this->getMemoryCache()->get('core-t3lib_TCEmain-elementsToBeDeleted'); + $elementsToBeDeleted = (array)$this->getMemoryCache()->get('core-t3lib_TCEmain-elementsToBeDeleted'); return isset($elementsToBeDeleted[$table][$id]); } @@ -7315,7 +7315,7 @@ class DataHandler { * @see process_datamap */ protected function registerElementsToBeDeleted() { - $elementsToBeDeleted = (array) $this->getMemoryCache()->get('core-t3lib_TCEmain-elementsToBeDeleted'); + $elementsToBeDeleted = (array)$this->getMemoryCache()->get('core-t3lib_TCEmain-elementsToBeDeleted'); $this->getMemoryCache()->set('core-t3lib_TCEmain-elementsToBeDeleted', array_merge($elementsToBeDeleted, $this->getCommandMapElements('delete'))); } diff --git a/typo3/sysext/core/Classes/DataHandling/TableColumnSubType.php b/typo3/sysext/core/Classes/DataHandling/TableColumnSubType.php index 6f450208edec2dad43cb177d143b354cfef6e3a8..2f8b2bd85cce4c6f92ae0e1d7e8aac8705627bb7 100644 --- a/typo3/sysext/core/Classes/DataHandling/TableColumnSubType.php +++ b/typo3/sysext/core/Classes/DataHandling/TableColumnSubType.php @@ -36,7 +36,7 @@ class TableColumnSubType extends \TYPO3\CMS\Core\Type\Enumeration { */ public function __construct($subType = NULL) { if ($subType !== NULL) { - $subType = strtoupper((string) $subType); + $subType = strtoupper((string)$subType); } parent::__construct($subType); diff --git a/typo3/sysext/core/Classes/DataHandling/TableColumnType.php b/typo3/sysext/core/Classes/DataHandling/TableColumnType.php index b770dded4cfc27b699acb6aa0a03cda9fecbca7e..28c43054e12e1320a3050eeaaf6ac36e020f0a1c 100644 --- a/typo3/sysext/core/Classes/DataHandling/TableColumnType.php +++ b/typo3/sysext/core/Classes/DataHandling/TableColumnType.php @@ -41,7 +41,7 @@ class TableColumnType extends \TYPO3\CMS\Core\Type\Enumeration { */ public function __construct($type = NULL) { if ($type !== NULL) { - $type = strtoupper((string) $type); + $type = strtoupper((string)$type); } parent::__construct($type); diff --git a/typo3/sysext/core/Classes/Database/DatabaseConnection.php b/typo3/sysext/core/Classes/Database/DatabaseConnection.php index 6ab51889d6af3899fbb58a4b647e41a617060d32..e115bd3ab92404b0c5901ca2847dbb746a90a223 100644 --- a/typo3/sysext/core/Classes/Database/DatabaseConnection.php +++ b/typo3/sysext/core/Classes/Database/DatabaseConnection.php @@ -409,7 +409,7 @@ class DatabaseConnection { * @param string $field Name of the field to use in the COUNT() expression (e.g. '*') * @param string $table Name of the table to count rows for * @param string $where (optional) WHERE statement of the query - * @return mixed Number of rows counter (integer) or FALSE if something went wrong (boolean) + * @return mixed Number of rows counter (int) or FALSE if something went wrong (bool) */ public function exec_SELECTcountRows($field, $table, $where = '') { $count = FALSE; diff --git a/typo3/sysext/core/Classes/Database/QueryView.php b/typo3/sysext/core/Classes/Database/QueryView.php index b4d2edc1a3c17cf08948aad98a9938ba1e31b524..824920b5832c30b3833c3d6e55dab90a1ccb406a 100644 --- a/typo3/sysext/core/Classes/Database/QueryView.php +++ b/typo3/sysext/core/Classes/Database/QueryView.php @@ -520,7 +520,7 @@ class QueryView { $out .= '<td nowrap>'; if (!$row['deleted']) { $out .= '<a href="#" onClick="top.launchView(\'' . $table . '\',' . $row['uid'] . ',\'' . $GLOBALS['BACK_PATH'] . '\');return false;">' . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('status-dialog-information') . '</a>'; - $out .= '<a href="#" onClick="' . BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'], (GeneralUtility::getIndpEnv('REQUEST_URI') . GeneralUtility::implodeArrayForUrl('SET', (array) GeneralUtility::_POST('SET')))) . '">' . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('actions-document-open') . '</a>'; + $out .= '<a href="#" onClick="' . BackendUtility::editOnClick($params, $GLOBALS['BACK_PATH'], (GeneralUtility::getIndpEnv('REQUEST_URI') . GeneralUtility::implodeArrayForUrl('SET', (array)GeneralUtility::_POST('SET')))) . '">' . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('actions-document-open') . '</a>'; } else { $out .= '<a href="' . GeneralUtility::linkThisUrl(($GLOBALS['BACK_PATH'] . 'tce_db.php'), array( ('cmd[' . $table . '][' . $row['uid'] . '][undelete]') => '1', diff --git a/typo3/sysext/core/Classes/Database/ReferenceIndex.php b/typo3/sysext/core/Classes/Database/ReferenceIndex.php index 36e9823ba2d59066fdec294ae604af0a2d4b720b..29b6c1f194dbdb655a1967e66dec3bb29d875b65 100644 --- a/typo3/sysext/core/Classes/Database/ReferenceIndex.php +++ b/typo3/sysext/core/Classes/Database/ReferenceIndex.php @@ -175,7 +175,7 @@ class ReferenceIndex { $this->relations = array(); foreach ($dbrels as $fieldname => $dat) { // Based on type, - switch ((string) $dat['type']) { + switch ((string)$dat['type']) { case 'db': $this->createEntryData_dbRels($table, $uid, $fieldname, '', $deleted, $dat['itemArray']); break; @@ -311,7 +311,7 @@ class ReferenceIndex { if (is_array($elements)) { foreach ($elements as $subKey => $el) { if (is_array($el['subst'])) { - switch ((string) $el['subst']['type']) { + switch ((string)$el['subst']['type']) { case 'db': list($tableName, $recordId) = explode(':', $el['subst']['recordRef']); $this->relations[] = $this->createEntryData($table, $uid, $fieldname, $flexpointer, $deleted, $tableName, $recordId, '', -1, $spKey, $subKey); @@ -655,7 +655,7 @@ class ReferenceIndex { // Initialize data array that is to be sent to TCEmain afterwards: $dataArray = array(); // Based on type, - switch ((string) $dat['type']) { + switch ((string)$dat['type']) { case 'db': $error = $this->setReferenceValue_dbRels($refRec, $dat['itemArray'], $newValue, $dataArray); if ($error) { diff --git a/typo3/sysext/core/Classes/Database/RelationHandler.php b/typo3/sysext/core/Classes/Database/RelationHandler.php index 716980eaf168b3619cfbe227997e511fa4066126..b1dcf4cb97fc56296835a5fec456bd2c66583330 100644 --- a/typo3/sysext/core/Classes/Database/RelationHandler.php +++ b/typo3/sysext/core/Classes/Database/RelationHandler.php @@ -256,7 +256,7 @@ class RelationHandler { public function start($itemlist, $tablelist, $MMtable = '', $MMuid = 0, $currentTable = '', $conf = array()) { $conf = (array)$conf; // SECTION: MM reverse relations - $this->MM_is_foreign = (boolean)$conf['MM_opposite_field']; + $this->MM_is_foreign = (bool)$conf['MM_opposite_field']; $this->MM_oppositeField = $conf['MM_opposite_field']; $this->MM_table_where = $conf['MM_table_where']; $this->MM_hasUidField = $conf['MM_hasUidField']; @@ -342,7 +342,7 @@ class RelationHandler { * @param bool $allFields enables fetching of all fields in getFromDB() */ public function setFetchAllFields($allFields) { - $this->fetchAllFields = (boolean)$allFields; + $this->fetchAllFields = (bool)$allFields; } /** @@ -352,7 +352,7 @@ class RelationHandler { * @return void */ public function setUpdateReferenceIndex($updateReferenceIndex) { - $this->updateReferenceIndex = (boolean)$updateReferenceIndex; + $this->updateReferenceIndex = (bool)$updateReferenceIndex; } /** @@ -377,7 +377,7 @@ class RelationHandler { * @return void */ public function readList($itemlist, array $configuration) { - if ((string) trim($itemlist) != '') { + if ((string)trim($itemlist) != '') { $tempItemArray = GeneralUtility::trimExplode(',', $itemlist); // Changed to trimExplode 31/3 04; HMENU special type "list" didn't work // if there were spaces in the list... I suppose this is better overall... @@ -397,7 +397,7 @@ class RelationHandler { ? strrev(trim($parts[1])) : ($this->secondTable && $theID < 0 ? $this->secondTable : $this->firstTable); // If the ID is not blank and the table name is among the names in the inputted tableList - if (((string) $theID != '' && $theID) && $theTable && isset($this->tableArray[$theTable])) { + if (((string)$theID != '' && $theID) && $theTable && isset($this->tableArray[$theTable])) { // Get ID as the right value: $theID = $this->secondTable ? abs((int)$theID) : (int)$theID; // Register ID/table name in internal arrays: diff --git a/typo3/sysext/core/Classes/Database/SoftReferenceIndex.php b/typo3/sysext/core/Classes/Database/SoftReferenceIndex.php index 16b1d645205d266f4e2a465fed68098b77f19199..4b2a25fd6c5ca28e3760537d142d70372cb7b5b2 100644 --- a/typo3/sysext/core/Classes/Database/SoftReferenceIndex.php +++ b/typo3/sysext/core/Classes/Database/SoftReferenceIndex.php @@ -677,7 +677,7 @@ class SoftReferenceIndex { $elements[$tokenID . ':' . $idx] = array(); $elements[$tokenID . ':' . $idx]['matchString'] = $content; // Based on link type, maybe do more: - switch ((string) $tLP['LINK_TYPE']) { + switch ((string)$tLP['LINK_TYPE']) { case 'mailto': case 'url': diff --git a/typo3/sysext/core/Classes/Error/DebugExceptionHandler.php b/typo3/sysext/core/Classes/Error/DebugExceptionHandler.php index 5ce905894ee5ced1340e68279ff1f464cec8dbab..06f0f0a1c1e026ed67e40ce9d8651c8d9d30b445 100644 --- a/typo3/sysext/core/Classes/Error/DebugExceptionHandler.php +++ b/typo3/sysext/core/Classes/Error/DebugExceptionHandler.php @@ -166,7 +166,7 @@ Uncaught TYPO3 Exception ' . $exceptionCodeNumber . $exception->getMessage() . L $arguments .= '"<span style="color:#FF8700;" title="' . htmlspecialchars($argument) . '">' . $preparedArgument . '</span>"'; } elseif (is_numeric($argument)) { - $arguments .= '<span style="color:#FF8700;">' . (string) $argument . '</span>'; + $arguments .= '<span style="color:#FF8700;">' . (string)$argument . '</span>'; } else { $arguments .= '<span style="color:#FF8700;"><em>' . gettype($argument) . '</em></span>'; } diff --git a/typo3/sysext/core/Classes/FormProtection/AbstractFormProtection.php b/typo3/sysext/core/Classes/FormProtection/AbstractFormProtection.php index eda3bc10e51f44fd866b4fa8c9eae07432b988a2..6ebb7152d359732601b73d925048d0786f19470d 100644 --- a/typo3/sysext/core/Classes/FormProtection/AbstractFormProtection.php +++ b/typo3/sysext/core/Classes/FormProtection/AbstractFormProtection.php @@ -94,8 +94,8 @@ abstract class AbstractFormProtection { * @return bool */ public function validateToken($tokenId, $formName, $action = '', $formInstanceName = '') { - $validTokenId = \TYPO3\CMS\Core\Utility\GeneralUtility::hmac(((string) $formName . (string) $action) . (string) $formInstanceName . $this->getSessionToken()); - if ((string) $tokenId === $validTokenId) { + $validTokenId = \TYPO3\CMS\Core\Utility\GeneralUtility::hmac(((string)$formName . (string)$action) . (string)$formInstanceName . $this->getSessionToken()); + if ((string)$tokenId === $validTokenId) { $isValid = TRUE; } else { $isValid = FALSE; diff --git a/typo3/sysext/core/Classes/FrontendEditing/FrontendEditingController.php b/typo3/sysext/core/Classes/FrontendEditing/FrontendEditingController.php index 7d979004b98aad3645c210a2d5e60bb0e38a9455..4a10f30a81a4da8a9e29f7f428e9912bff52a9f0 100644 --- a/typo3/sysext/core/Classes/FrontendEditing/FrontendEditingController.php +++ b/typo3/sysext/core/Classes/FrontendEditing/FrontendEditingController.php @@ -154,7 +154,7 @@ class FrontendEditingController { if ($this->TSFE_EDIT['cancel']) { unset($this->TSFE_EDIT['cmd']); } else { - $cmd = (string) $this->TSFE_EDIT['cmd']; + $cmd = (string)$this->TSFE_EDIT['cmd']; if (($cmd != 'edit' || is_array($this->TSFE_EDIT['data']) && ($this->TSFE_EDIT['doSave'] || $this->TSFE_EDIT['update'] || $this->TSFE_EDIT['update_close'])) && $cmd != 'new') { // $cmd can be a command like "hide" or "move". If $cmd is "edit" or "new" it's an indication to show the formfields. But if data is sent with update-flag then $cmd = edit is accepted because edit may be sent because of .keepGoing flag. return TRUE; @@ -173,7 +173,7 @@ class FrontendEditingController { */ public function isEditFormShown() { if (is_array($this->TSFE_EDIT)) { - $cmd = (string) $this->TSFE_EDIT['cmd']; + $cmd = (string)$this->TSFE_EDIT['cmd']; if ($cmd == 'edit' || $cmd == 'new') { return TRUE; } diff --git a/typo3/sysext/core/Classes/Html/RteHtmlParser.php b/typo3/sysext/core/Classes/Html/RteHtmlParser.php index d7015f5ec0a9b8453c6b7ba011c2636ce1b92810..50d5b1e1b19e12d66ccdd15e7410011dbb9e5456 100644 --- a/typo3/sysext/core/Classes/Html/RteHtmlParser.php +++ b/typo3/sysext/core/Classes/Html/RteHtmlParser.php @@ -189,7 +189,7 @@ class RteHtmlParser extends \TYPO3\CMS\Core\Html\HtmlParser { public function RTE_transform($value, $specConf, $direction = 'rte', $thisConfig = array()) { // Init: $this->tsConfig = $thisConfig; - $this->procOptions = (array) $thisConfig['proc.']; + $this->procOptions = (array)$thisConfig['proc.']; $this->preserveTags = strtoupper(implode(',', GeneralUtility::trimExplode(',', $this->procOptions['preserveTags']))); // dynamic configuration of blockElementList if ($this->procOptions['blockElementList']) { @@ -1691,7 +1691,7 @@ class RteHtmlParser extends \TYPO3\CMS\Core\Html\HtmlParser { protected function applyPlainImageModeSettings($imageInfo, $attribArray) { if ($this->procOptions['plainImageMode']) { // Perform corrections to aspect ratio based on configuration - switch ((string) $this->procOptions['plainImageMode']) { + switch ((string)$this->procOptions['plainImageMode']) { case 'lockDimensions': $attribArray['width'] = $imageInfo[0]; $attribArray['height'] = $imageInfo[1]; diff --git a/typo3/sysext/core/Classes/Http/HttpRequest.php b/typo3/sysext/core/Classes/Http/HttpRequest.php index c57dab7b1ca22152f7bebded40d93d6f2aee568e..c7b25359d175f9e29103f58306bea6a5a75a5634 100644 --- a/typo3/sysext/core/Classes/Http/HttpRequest.php +++ b/typo3/sysext/core/Classes/Http/HttpRequest.php @@ -55,16 +55,16 @@ class HttpRequest extends \HTTP_Request2 { 'connect_timeout' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['connect_timeout'], 'timeout' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['timeout'], 'protocol_version' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['protocol_version'], - 'follow_redirects' => (bool) $GLOBALS['TYPO3_CONF_VARS']['HTTP']['follow_redirects'], + 'follow_redirects' => (bool)$GLOBALS['TYPO3_CONF_VARS']['HTTP']['follow_redirects'], 'max_redirects' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['max_redirects'], - 'strict_redirects' => (bool) $GLOBALS['TYPO3_CONF_VARS']['HTTP']['strict_redirects'], + 'strict_redirects' => (bool)$GLOBALS['TYPO3_CONF_VARS']['HTTP']['strict_redirects'], 'proxy_host' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['proxy_host'], 'proxy_port' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['proxy_port'], 'proxy_user' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['proxy_user'], 'proxy_password' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['proxy_password'], 'proxy_auth_scheme' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['proxy_auth_scheme'], - 'ssl_verify_peer' => (bool) $GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_verify_peer'], - 'ssl_verify_host' => (bool) $GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_verify_host'], + 'ssl_verify_peer' => (bool)$GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_verify_peer'], + 'ssl_verify_host' => (bool)$GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_verify_host'], // we have to deal with Install Tool limitations and set this to NULL if it is empty 'ssl_cafile' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_cafile'] ?: NULL, 'ssl_capath' => $GLOBALS['TYPO3_CONF_VARS']['HTTP']['ssl_capath'] ?: NULL, diff --git a/typo3/sysext/core/Classes/Imaging/GraphicalFunctions.php b/typo3/sysext/core/Classes/Imaging/GraphicalFunctions.php index f40fb3285880aa33c4cc914f8bf8d8e33b5e0fb9..bf1aeadb66b7f53dbafa24f2424ebd0ba3344cdd 100644 --- a/typo3/sysext/core/Classes/Imaging/GraphicalFunctions.php +++ b/typo3/sysext/core/Classes/Imaging/GraphicalFunctions.php @@ -1054,7 +1054,7 @@ class GraphicalFunctions { foreach ($sKeyArray as $key) { $cfg = $splitRendering[$key . '.']; // Process each type of split rendering keyword: - switch ((string) $splitRendering[$key]) { + switch ((string)$splitRendering[$key]) { case 'highlightWord': if (strlen($cfg['value'])) { $newResult = array(); diff --git a/typo3/sysext/core/Classes/Localization/LanguageStore.php b/typo3/sysext/core/Classes/Localization/LanguageStore.php index bbaa12075c46f3a6253ac48c2707236f8c544f7d..28490c6b7f1bf3f0f4d313e9df92d5a37b2dcb3a 100644 --- a/typo3/sysext/core/Classes/Localization/LanguageStore.php +++ b/typo3/sysext/core/Classes/Localization/LanguageStore.php @@ -189,7 +189,7 @@ class LanguageStore implements \TYPO3\CMS\Core\SingletonInterface { */ public function getParserInstance($fileReference) { if (isset($this->configuration[$fileReference]['parserClass']) && trim($this->configuration[$fileReference]['parserClass']) !== '') { - return \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance((string) $this->configuration[$fileReference]['parserClass']); + return \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance((string)$this->configuration[$fileReference]['parserClass']); } else { throw new \TYPO3\CMS\Core\Localization\Exception\InvalidParserException(sprintf('Invalid parser configuration for the current file (%s)', $fileReference), 1307293692); } @@ -204,7 +204,7 @@ class LanguageStore implements \TYPO3\CMS\Core\SingletonInterface { */ public function getAbsoluteFileReference($fileReference) { if (isset($this->configuration[$fileReference]['fileReference']) && trim($this->configuration[$fileReference]['fileReference']) !== '') { - return (string) $this->configuration[$fileReference]['fileReference']; + return (string)$this->configuration[$fileReference]['fileReference']; } else { throw new \InvalidArgumentException(sprintf('Invalid file reference configuration for the current file (%s)', $fileReference), 1307293693); } diff --git a/typo3/sysext/core/Classes/Localization/Parser/LocallangArrayParser.php b/typo3/sysext/core/Classes/Localization/Parser/LocallangArrayParser.php index 004f480365a11ee4b81f98279e2bd29a7eb9b2f6..edf46a9072b130dbda9c60ff340f84c0f068c2df 100644 --- a/typo3/sysext/core/Classes/Localization/Parser/LocallangArrayParser.php +++ b/typo3/sysext/core/Classes/Localization/Parser/LocallangArrayParser.php @@ -173,9 +173,9 @@ class LocallangArrayParser implements \TYPO3\CMS\Core\Localization\Parser\Locali * @return array */ protected function getContentFromCacheFile() { - $serContent = (array) unserialize(file_get_contents($this->cacheFileName)); + $serContent = (array)unserialize(file_get_contents($this->cacheFileName)); $LOCAL_LANG = $serContent['LOCAL_LANG']; - return (array) $LOCAL_LANG; + return (array)$LOCAL_LANG; } /** @@ -185,7 +185,7 @@ class LocallangArrayParser implements \TYPO3\CMS\Core\Localization\Parser\Locali * @return bool */ protected function isWithinWebRoot($fileName) { - return (bool) \TYPO3\CMS\Core\Utility\GeneralUtility::getFileAbsFileName($fileName); + return (bool)\TYPO3\CMS\Core\Utility\GeneralUtility::getFileAbsFileName($fileName); } /** diff --git a/typo3/sysext/core/Classes/Localization/Parser/LocallangXmlParser.php b/typo3/sysext/core/Classes/Localization/Parser/LocallangXmlParser.php index ac18b6fd13df0098b99ce0cdd15261d3ce2763d2..b930f98a261d3f0f5a33d482e48ae5ba02940a99 100644 --- a/typo3/sysext/core/Classes/Localization/Parser/LocallangXmlParser.php +++ b/typo3/sysext/core/Classes/Localization/Parser/LocallangXmlParser.php @@ -105,8 +105,8 @@ class LocallangXmlParser extends \TYPO3\CMS\Core\Localization\Parser\AbstractXml foreach ($children as $translationElement) { if ($translationElement->getName() === 'label') { // If restype would be set, it could be metadata from Gettext to XLIFF conversion (and we don't need this data) - $parsedData[(string) $translationElement['index']][0] = array( - $element => (string) $translationElement + $parsedData[(string)$translationElement['index']][0] = array( + $element => (string)$translationElement ); } } diff --git a/typo3/sysext/core/Classes/Localization/Parser/XliffParser.php b/typo3/sysext/core/Classes/Localization/Parser/XliffParser.php index 7505705c796fbe76b94046fc09659b01549ed32a..ae0ef955bd2d8b337de046f42a0e16e1007aa656 100644 --- a/typo3/sysext/core/Classes/Localization/Parser/XliffParser.php +++ b/typo3/sysext/core/Classes/Localization/Parser/XliffParser.php @@ -35,44 +35,44 @@ class XliffParser extends \TYPO3\CMS\Core\Localization\Parser\AbstractXmlParser // If restype would be set, it could be metadata from Gettext to XLIFF conversion (and we don't need this data) if ($this->languageKey === 'default') { // Default language coming from an XLIFF template (no target element) - $parsedData[(string) $translationElement['id']][0] = array( - 'source' => (string) $translationElement->source, - 'target' => (string) $translationElement->source + $parsedData[(string)$translationElement['id']][0] = array( + 'source' => (string)$translationElement->source, + 'target' => (string)$translationElement->source ); } else { // @todo Support "approved" attribute - $parsedData[(string) $translationElement['id']][0] = array( - 'source' => (string) $translationElement->source, - 'target' => (string) $translationElement->target + $parsedData[(string)$translationElement['id']][0] = array( + 'source' => (string)$translationElement->source, + 'target' => (string)$translationElement->target ); } - } elseif ($translationElement->getName() === 'group' && isset($translationElement['restype']) && (string) $translationElement['restype'] === 'x-gettext-plurals') { + } elseif ($translationElement->getName() === 'group' && isset($translationElement['restype']) && (string)$translationElement['restype'] === 'x-gettext-plurals') { // This is a translation with plural forms $parsedTranslationElement = array(); foreach ($translationElement->children() as $translationPluralForm) { if ($translationPluralForm->getName() === 'trans-unit') { // When using plural forms, ID looks like this: 1[0], 1[1] etc - $formIndex = substr((string) $translationPluralForm['id'], strpos((string) $translationPluralForm['id'], '[') + 1, -1); + $formIndex = substr((string)$translationPluralForm['id'], strpos((string)$translationPluralForm['id'], '[') + 1, -1); if ($this->languageKey === 'default') { // Default language come from XLIFF template (no target element) $parsedTranslationElement[(int)$formIndex] = array( - 'source' => (string) $translationPluralForm->source, - 'target' => (string) $translationPluralForm->source + 'source' => (string)$translationPluralForm->source, + 'target' => (string)$translationPluralForm->source ); } else { // @todo Support "approved" attribute $parsedTranslationElement[(int)$formIndex] = array( - 'source' => (string) $translationPluralForm->source, - 'target' => (string) $translationPluralForm->target + 'source' => (string)$translationPluralForm->source, + 'target' => (string)$translationPluralForm->target ); } } } if (!empty($parsedTranslationElement)) { if (isset($translationElement['id'])) { - $id = (string) $translationElement['id']; + $id = (string)$translationElement['id']; } else { - $id = (string) $translationElement->{'trans-unit'}[0]['id']; + $id = (string)$translationElement->{'trans-unit'}[0]['id']; $id = substr($id, 0, strpos($id, '[')); } $parsedData[$id] = $parsedTranslationElement; diff --git a/typo3/sysext/core/Classes/Log/Processor/AbstractMemoryProcessor.php b/typo3/sysext/core/Classes/Log/Processor/AbstractMemoryProcessor.php index 08d73b81bd71bf61119229acf8ea68ec1dfea8fd..24310150a8714ba14d99cb8f910c3584113d50c9 100644 --- a/typo3/sysext/core/Classes/Log/Processor/AbstractMemoryProcessor.php +++ b/typo3/sysext/core/Classes/Log/Processor/AbstractMemoryProcessor.php @@ -47,7 +47,7 @@ abstract class AbstractMemoryProcessor extends \TYPO3\CMS\Core\Log\Processor\Abs * @return void */ public function setRealMemoryUsage($realMemoryUsage) { - $this->realMemoryUsage = (bool) $realMemoryUsage; + $this->realMemoryUsage = (bool)$realMemoryUsage; } /** @@ -66,7 +66,7 @@ abstract class AbstractMemoryProcessor extends \TYPO3\CMS\Core\Log\Processor\Abs * @return void */ public function setFormatSize($formatSize) { - $this->formatSize = (bool) $formatSize; + $this->formatSize = (bool)$formatSize; } /** diff --git a/typo3/sysext/core/Classes/Log/Processor/IntrospectionProcessor.php b/typo3/sysext/core/Classes/Log/Processor/IntrospectionProcessor.php index 17620c8b835815945168a740ac7a53b9daf911f4..d238bbc856779a67866356056c72df6059cebc2a 100644 --- a/typo3/sysext/core/Classes/Log/Processor/IntrospectionProcessor.php +++ b/typo3/sysext/core/Classes/Log/Processor/IntrospectionProcessor.php @@ -57,7 +57,7 @@ class IntrospectionProcessor extends \TYPO3\CMS\Core\Log\Processor\AbstractProce * @return \TYPO3\CMS\Core\Log\Writer\AbstractWriter */ public function setShiftBackTraceLevel($shiftBackTraceLevel) { - $this->shiftBackTraceLevel = (int) $shiftBackTraceLevel; + $this->shiftBackTraceLevel = (int)$shiftBackTraceLevel; return $this; } @@ -68,7 +68,7 @@ class IntrospectionProcessor extends \TYPO3\CMS\Core\Log\Processor\AbstractProce * @return \TYPO3\CMS\Core\Log\Writer\AbstractWriter */ public function setAppendFullBackTrace($appendFullBackTrace) { - $this->appendFullBackTrace = (bool) $appendFullBackTrace; + $this->appendFullBackTrace = (bool)$appendFullBackTrace; return $this; } diff --git a/typo3/sysext/core/Classes/Mail/Mailer.php b/typo3/sysext/core/Classes/Mail/Mailer.php index 15805470dafb684e89e380e5b3e4427a47e0f728..1d0fc47b5d8dc120a415b9269b0b2ff297a5033e 100644 --- a/typo3/sysext/core/Classes/Mail/Mailer.php +++ b/typo3/sysext/core/Classes/Mail/Mailer.php @@ -142,7 +142,7 @@ class Mailer extends \Swift_Mailer { if (is_array($mailSettings)) { $this->mailSettings = $mailSettings; } else { - $this->mailSettings = (array) $GLOBALS['TYPO3_CONF_VARS']['MAIL']; + $this->mailSettings = (array)$GLOBALS['TYPO3_CONF_VARS']['MAIL']; } } diff --git a/typo3/sysext/core/Classes/Mail/MboxTransport.php b/typo3/sysext/core/Classes/Mail/MboxTransport.php index da73f841fdb3604d03d259ae74ddf293b6e7c807..f7e4ca72c28f4d70c2fdb6454a6bb46d53630f76 100644 --- a/typo3/sysext/core/Classes/Mail/MboxTransport.php +++ b/typo3/sysext/core/Classes/Mail/MboxTransport.php @@ -89,7 +89,7 @@ class MboxTransport implements \Swift_Transport { \TYPO3\CMS\Core\Utility\GeneralUtility::fixPermissions($this->debugFile); $lockObject->release(); // Return every receipient as "delivered" - $count = count((array) $message->getTo()) + count((array) $message->getCc()) + count((array) $message->getBcc()); + $count = count((array)$message->getTo()) + count((array)$message->getCc()) + count((array)$message->getBcc()); return $count; } diff --git a/typo3/sysext/core/Classes/Messaging/AbstractMessage.php b/typo3/sysext/core/Classes/Messaging/AbstractMessage.php index c1eaf299b78f322409a827d145b23fc2ca759e5a..0485c8a0d91f7fa9bf7e59a84e77c6f1f2bcb4b6 100644 --- a/typo3/sysext/core/Classes/Messaging/AbstractMessage.php +++ b/typo3/sysext/core/Classes/Messaging/AbstractMessage.php @@ -63,7 +63,7 @@ abstract class AbstractMessage { * @return void */ public function setTitle($title) { - $this->title = (string) $title; + $this->title = (string)$title; } /** @@ -82,7 +82,7 @@ abstract class AbstractMessage { * @return void */ public function setMessage($message) { - $this->message = (string) $message; + $this->message = (string)$message; } /** diff --git a/typo3/sysext/core/Classes/Page/PageRenderer.php b/typo3/sysext/core/Classes/Page/PageRenderer.php index e08a70b3d4441cb635f7f80bddf554a038baa28f..99c224fe73b92c0dc72c25bd361395fc9d32e574 100644 --- a/typo3/sysext/core/Classes/Page/PageRenderer.php +++ b/typo3/sysext/core/Classes/Page/PageRenderer.php @@ -1900,9 +1900,9 @@ class PageRenderer implements \TYPO3\CMS\Core\SingletonInterface { foreach ($parts as $part) { $a = &$a[$part]; } - $a = array_merge((array) $a, $array); + $a = array_merge((array)$a, $array); } else { - $this->inlineSettings[$namespace] = array_merge((array) $this->inlineSettings[$namespace], $array); + $this->inlineSettings[$namespace] = array_merge((array)$this->inlineSettings[$namespace], $array); } } else { $this->inlineSettings = array_merge($this->inlineSettings, $array); diff --git a/typo3/sysext/core/Classes/Resource/File.php b/typo3/sysext/core/Classes/Resource/File.php index 039762b41a5a9eac44515cd7a64705ef0d791ebc..793b7a297a5c3591cdde7efdcb35ac5c09f34aff 100644 --- a/typo3/sysext/core/Classes/Resource/File.php +++ b/typo3/sysext/core/Classes/Resource/File.php @@ -340,7 +340,7 @@ class File extends AbstractFile { * @return bool */ public function isMissing() { - return (bool) $this->getProperty('missing'); + return (bool)$this->getProperty('missing'); } /** @@ -388,7 +388,7 @@ class File extends AbstractFile { * @internal Only for usage in Indexer */ public function setIndexingInProgess($indexingState) { - $this->indexingInProgress = (boolean)$indexingState; + $this->indexingInProgress = (bool)$indexingState; } /** diff --git a/typo3/sysext/core/Classes/Resource/FileReference.php b/typo3/sysext/core/Classes/Resource/FileReference.php index 7d35d64914f2b2acf24c939546c7b2cb20d7133b..367187e035f32bb883b8811218666b99ec1e666a 100644 --- a/typo3/sysext/core/Classes/Resource/FileReference.php +++ b/typo3/sysext/core/Classes/Resource/FileReference.php @@ -319,7 +319,7 @@ class FileReference implements FileInterface { * @return bool */ public function isMissing() { - return (bool) $this->originalFile->getProperty('missing'); + return (bool)$this->originalFile->getProperty('missing'); } /****************** diff --git a/typo3/sysext/core/Classes/Resource/Filter/FileNameFilter.php b/typo3/sysext/core/Classes/Resource/Filter/FileNameFilter.php index 6c571a232e0c261877aa71a36fc313340400272a..9f040322fccfb0dcb3a87dcb0927d1cbc186a3fa 100644 --- a/typo3/sysext/core/Classes/Resource/Filter/FileNameFilter.php +++ b/typo3/sysext/core/Classes/Resource/Filter/FileNameFilter.php @@ -67,7 +67,7 @@ class FileNameFilter { * @return bool */ static public function setShowHiddenFilesAndFolders($showHiddenFilesAndFolders) { - return self::$showHiddenFilesAndFolders = (bool) $showHiddenFilesAndFolders; + return self::$showHiddenFilesAndFolders = (bool)$showHiddenFilesAndFolders; } } diff --git a/typo3/sysext/core/Classes/Resource/Folder.php b/typo3/sysext/core/Classes/Resource/Folder.php index 5e1a0ec7e2ff46d61189784b84709ad43fa8692b..e55dda22554b05eb04f6775650a1766c1abbc88c 100644 --- a/typo3/sysext/core/Classes/Resource/Folder.php +++ b/typo3/sysext/core/Classes/Resource/Folder.php @@ -375,7 +375,7 @@ class Folder implements FolderInterface { * Prepares the filters in this folder's storage according to a set filter mode. * * @param int $filterMode The filter mode to use; one of the FILTER_MODE_* constants - * @return array The backed up filters as an array (NULL if filters were not backed up) and whether to use filters or not (boolean) + * @return array The backed up filters as an array (NULL if filters were not backed up) and whether to use filters or not (bool) */ protected function prepareFiltersInStorage($filterMode) { $backedUpFilters = NULL; diff --git a/typo3/sysext/core/Classes/Resource/Service/MagicImageService.php b/typo3/sysext/core/Classes/Resource/Service/MagicImageService.php index cac6265693fb957f18ef6f6b19c876b823b83e29..6f6209369c55f7837a8e414eef6d7b5e5581eddd 100644 --- a/typo3/sysext/core/Classes/Resource/Service/MagicImageService.php +++ b/typo3/sysext/core/Classes/Resource/Service/MagicImageService.php @@ -75,11 +75,11 @@ class MagicImageService { // Get maximum dimensions from the configuration of the RTE image button $imageButtonConfiguration = (is_array($rteConfiguration['buttons.']) && is_array($rteConfiguration['buttons.']['image.'])) ? $rteConfiguration['buttons.']['image.'] : array(); if (is_array($imageButtonConfiguration['options.']) && is_array($imageButtonConfiguration['options.']['magic.'])) { - if ((int) $imageButtonConfiguration['options.']['magic.']['maxWidth'] > 0) { - $this->magicImageMaximumWidth = (int) $imageButtonConfiguration['options.']['magic.']['maxWidth']; + if ((int)$imageButtonConfiguration['options.']['magic.']['maxWidth'] > 0) { + $this->magicImageMaximumWidth = (int)$imageButtonConfiguration['options.']['magic.']['maxWidth']; } - if ((int) $imageButtonConfiguration['options.']['magic.']['maxHeight'] > 0) { - $this->magicImageMaximumHeight = (int) $imageButtonConfiguration['options.']['magic.']['maxHeight']; + if ((int)$imageButtonConfiguration['options.']['magic.']['maxHeight'] > 0) { + $this->magicImageMaximumHeight = (int)$imageButtonConfiguration['options.']['magic.']['maxHeight']; } } } diff --git a/typo3/sysext/core/Classes/Tree/TableConfiguration/DatabaseTreeDataProvider.php b/typo3/sysext/core/Classes/Tree/TableConfiguration/DatabaseTreeDataProvider.php index 972b578586f7b84478887e282d32ede30cd5cc78..f419f9a239a0b835832c33dc2a058ddc5ad386ca 100644 --- a/typo3/sysext/core/Classes/Tree/TableConfiguration/DatabaseTreeDataProvider.php +++ b/typo3/sysext/core/Classes/Tree/TableConfiguration/DatabaseTreeDataProvider.php @@ -356,7 +356,7 @@ class DatabaseTreeDataProvider extends \TYPO3\CMS\Core\Tree\TableConfiguration\A */ protected function getChildrenUidsFromParentRelation(array $row) { $uid = $row['uid']; - switch ((string) $this->columnConfiguration['type']) { + switch ((string)$this->columnConfiguration['type']) { case 'inline': case 'select': @@ -389,7 +389,7 @@ class DatabaseTreeDataProvider extends \TYPO3\CMS\Core\Tree\TableConfiguration\A $relatedUids = array(); $uid = $row['uid']; $value = $row[$this->getLookupField()]; - switch ((string) $this->columnConfiguration['type']) { + switch ((string)$this->columnConfiguration['type']) { case 'inline': case 'select': diff --git a/typo3/sysext/core/Classes/Tree/TableConfiguration/DatabaseTreeNode.php b/typo3/sysext/core/Classes/Tree/TableConfiguration/DatabaseTreeNode.php index e97b907c14c9b1266622d955a3bc02e18b926bb2..a946be26c310ae83a4bf6196dc1c32e0b252130d 100644 --- a/typo3/sysext/core/Classes/Tree/TableConfiguration/DatabaseTreeNode.php +++ b/typo3/sysext/core/Classes/Tree/TableConfiguration/DatabaseTreeNode.php @@ -118,7 +118,7 @@ class DatabaseTreeNode extends \TYPO3\CMS\Backend\Tree\TreeRepresentationNode { * @return void */ public function setHasChildren($value) { - $this->hasChildren = (bool) $value; + $this->hasChildren = (bool)$value; } /** diff --git a/typo3/sysext/core/Classes/Tree/TableConfiguration/TreeDataProviderFactory.php b/typo3/sysext/core/Classes/Tree/TableConfiguration/TreeDataProviderFactory.php index 50fe046ea7bbb40380dd1175b28cd5b0094761ed..60813a4b7b64edbab2e90cf105f8e0d905a31287 100644 --- a/typo3/sysext/core/Classes/Tree/TableConfiguration/TreeDataProviderFactory.php +++ b/typo3/sysext/core/Classes/Tree/TableConfiguration/TreeDataProviderFactory.php @@ -71,7 +71,7 @@ class TreeDataProviderFactory { $dataProvider->setRootUid((int)$treeConfiguration['rootUid']); } if (isset($treeConfiguration['appearance']['expandAll'])) { - $dataProvider->setExpandAll((bool) $treeConfiguration['appearance']['expandAll']); + $dataProvider->setExpandAll((bool)$treeConfiguration['appearance']['expandAll']); } if (isset($treeConfiguration['appearance']['maxLevels'])) { $dataProvider->setLevelMaximum((int)$treeConfiguration['appearance']['maxLevels']); diff --git a/typo3/sysext/core/Classes/Type/Enumeration.php b/typo3/sysext/core/Classes/Type/Enumeration.php index 2db43faecb109b339e9a5ed8545a50261ee452ef..d83313be03c409c7319ed7324471c232a44409a1 100644 --- a/typo3/sysext/core/Classes/Type/Enumeration.php +++ b/typo3/sysext/core/Classes/Type/Enumeration.php @@ -142,9 +142,9 @@ abstract class Enumeration implements TypeInterface { * @return bool */ protected function isValid($value) { - $value = (string) $value; + $value = (string)$value; foreach (static::$enumConstants[get_class($this)] as $constantValue) { - if ($value === (string) $constantValue) { + if ($value === (string)$constantValue) { return TRUE; } } diff --git a/typo3/sysext/core/Classes/TypoScript/TemplateService.php b/typo3/sysext/core/Classes/TypoScript/TemplateService.php index f14b170b6fad49bdf46af68533277221e423218f..d6d033be4a636bcf339fd09f23e51a68ca644384 100644 --- a/typo3/sysext/core/Classes/TypoScript/TemplateService.php +++ b/typo3/sysext/core/Classes/TypoScript/TemplateService.php @@ -205,7 +205,7 @@ class TemplateService { * @param bool $processExtensionStatics */ public function setProcessExtensionStatics($processExtensionStatics) { - $this->processExtensionStatics = (bool) $processExtensionStatics; + $this->processExtensionStatics = (bool)$processExtensionStatics; } /** @@ -285,7 +285,7 @@ class TemplateService { if (is_array($cc['all'])) { /** @var $matchObj \TYPO3\CMS\Frontend\Configuration\TypoScript\ConditionMatching\ConditionMatcher */ $matchObj = GeneralUtility::makeInstance('TYPO3\\CMS\\Frontend\\Configuration\\TypoScript\\ConditionMatching\\ConditionMatcher'); - $matchObj->setRootline((array) $cc['rootLine']); + $matchObj->setRootline((array)$cc['rootLine']); foreach ($cc['all'] as $key => $pre) { if ($matchObj->match($pre)) { $sectionsMatch[$key] = $pre; @@ -805,7 +805,7 @@ class TemplateService { /** @var $matchObj \TYPO3\CMS\Frontend\Configuration\TypoScript\ConditionMatching\ConditionMatcher */ $matchObj = GeneralUtility::makeInstance('TYPO3\\CMS\\Frontend\\Configuration\\TypoScript\\ConditionMatching\\ConditionMatcher'); $matchObj->setSimulateMatchConditions($this->matchAlternative); - $matchObj->setSimulateMatchResult((bool) $this->matchAll); + $matchObj->setSimulateMatchResult((bool)$this->matchAll); // Traverse constants text fields and parse them foreach ($this->constants as $str) { $constants->parse($str, $matchObj); diff --git a/typo3/sysext/core/Classes/Utility/DebugUtility.php b/typo3/sysext/core/Classes/Utility/DebugUtility.php index 7cef61f175d161db83747cac3e021dba8b8ae8ab..a578b58c344615ccfa31a49662f0d7455e4efe68 100644 --- a/typo3/sysext/core/Classes/Utility/DebugUtility.php +++ b/typo3/sysext/core/Classes/Utility/DebugUtility.php @@ -53,7 +53,7 @@ class DebugUtility { } $debug = self::convertVariableToString($var); if ($header) { - $debug = sprintf(self::DEBUG_TABLE_TEMPLATE, htmlspecialchars((string) $header), $debug); + $debug = sprintf(self::DEBUG_TABLE_TEMPLATE, htmlspecialchars((string)$header), $debug); } if (TYPO3_MODE === 'BE' && !(TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_CLI)) { $tabHeader = $header ?: 'Debug'; @@ -108,8 +108,8 @@ class DebugUtility { $string = '<strong>|Object:<pre>'; $string .= print_r($variable, TRUE); $string .= '</pre>|</strong>'; - } elseif ((string) $variable !== '') { - $string = '<strong>|' . htmlspecialchars((string) $variable) . '|</strong>'; + } elseif ((string)$variable !== '') { + $string = '<strong>|' . htmlspecialchars((string)$variable) . '|</strong>'; } else { $string = '<strong>| debug |</strong>'; } @@ -271,14 +271,14 @@ class DebugUtility { } else { foreach ($array_in as $key => $val) { $result .= '<tr> - <td valign="top"><font face="Verdana,Arial" size="1">' . htmlspecialchars((string) $key) . '</font></td> + <td valign="top"><font face="Verdana,Arial" size="1">' . htmlspecialchars((string)$key) . '</font></td> <td>'; if (is_array($val)) { $result .= self::viewArray($val); } elseif (is_object($val)) { $string = ''; if (method_exists($val, '__toString')) { - $string .= get_class($val) . ': ' . (string) $val; + $string .= get_class($val) . ': ' . (string)$val; } else { $string .= print_r($val, TRUE); } @@ -287,7 +287,7 @@ class DebugUtility { if (gettype($val) == 'object') { $string = 'Unknown object'; } else { - $string = (string) $val; + $string = (string)$val; } $result .= '<font face="Verdana,Arial" size="1" color="red">' . nl2br(htmlspecialchars($string)) . '<br /></font>'; } @@ -299,7 +299,7 @@ class DebugUtility { } else { $result = '<table border="1" cellpadding="1" cellspacing="0" bgcolor="white"> <tr> - <td><font face="Verdana,Arial" size="1" color="red">' . nl2br(htmlspecialchars((string) $array_in)) . '<br /></font></td> + <td><font face="Verdana,Arial" size="1" color="red">' . nl2br(htmlspecialchars((string)$array_in)) . '<br /></font></td> </tr> </table>'; } diff --git a/typo3/sysext/core/Classes/Utility/ExtensionManagementUtility.php b/typo3/sysext/core/Classes/Utility/ExtensionManagementUtility.php index 045570e56c9244f98589e7b989eb7d165a619011..b07cc3d5a8ae98c9ad126df876d6723cc0a3023c 100644 --- a/typo3/sysext/core/Classes/Utility/ExtensionManagementUtility.php +++ b/typo3/sysext/core/Classes/Utility/ExtensionManagementUtility.php @@ -176,7 +176,7 @@ class ExtensionManagementUtility { * Returns the real extension key like 'tt_news' from an extension prefix like 'tx_ttnews'. * * @param string $prefix The extension prefix (e.g. 'tx_ttnews') - * @return mixed Real extension key (string) or FALSE (boolean) if something went wrong + * @return mixed Real extension key (string)or FALSE (bool) if something went wrong */ static public function getExtensionKeyByPrefix($prefix) { $result = FALSE; diff --git a/typo3/sysext/core/Classes/Utility/File/BasicFileUtility.php b/typo3/sysext/core/Classes/Utility/File/BasicFileUtility.php index e4147b704f73de84f7bccfb68b89c8b764e6e600..76b81a91f4c9db69fdc26e31d0add55861abd128 100644 --- a/typo3/sysext/core/Classes/Utility/File/BasicFileUtility.php +++ b/typo3/sysext/core/Classes/Utility/File/BasicFileUtility.php @@ -193,7 +193,7 @@ class BasicFileUtility { public function checkIfFullAccess($theDest) { $type = $this->is_webpath($theDest) ? 'webspace' : 'ftpspace'; if (isset($this->f_ext[$type])) { - if ((string) $this->f_ext[$type]['deny'] == '' || $this->f_ext[$type]['allow'] == '*') { + if ((string)$this->f_ext[$type]['deny'] == '' || $this->f_ext[$type]['allow'] == '*') { return TRUE; } } diff --git a/typo3/sysext/core/Classes/Utility/File/ExtendedFileUtility.php b/typo3/sysext/core/Classes/Utility/File/ExtendedFileUtility.php index 169e65b447f1b7500df1da9e292fc6788dedb865..b3f5dd797e5eb874caefe4c6154a3cf554aefda5 100644 --- a/typo3/sysext/core/Classes/Utility/File/ExtendedFileUtility.php +++ b/typo3/sysext/core/Classes/Utility/File/ExtendedFileUtility.php @@ -492,7 +492,7 @@ class ExtendedFileUtility extends BasicFileUtility { return FALSE; } // If this is TRUE, we append _XX to the file name if - $appendSuffixOnConflict = (string) $cmds['altName']; + $appendSuffixOnConflict = (string)$cmds['altName']; $resultObject = NULL; // Copying the file if ($sourceFileObject instanceof File) { @@ -567,7 +567,7 @@ class ExtendedFileUtility extends BasicFileUtility { $this->writelog(3, 2, 100, 'Destination "%s" was not a directory', array($cmds['target'])); return FALSE; } - $alternativeName = (string) $cmds['altName']; + $alternativeName = (string)$cmds['altName']; $resultObject = NULL; // Moving the file if ($sourceFileObject instanceof File) { diff --git a/typo3/sysext/core/Classes/Utility/GeneralUtility.php b/typo3/sysext/core/Classes/Utility/GeneralUtility.php index f5ac305d3d417b08ce37db0b1e982fb8c5664521..6fd96e26ac6879b7858c8811b9979cf5615193db 100644 --- a/typo3/sysext/core/Classes/Utility/GeneralUtility.php +++ b/typo3/sysext/core/Classes/Utility/GeneralUtility.php @@ -342,7 +342,7 @@ class GeneralUtility { static public function read_png_gif($theFile, $output_png = FALSE) { if ($GLOBALS['TYPO3_CONF_VARS']['GFX']['im'] && @is_file($theFile)) { $ext = strtolower(substr($theFile, -4, 4)); - if ((string) $ext == '.png' && $output_png || (string) $ext == '.gif' && !$output_png) { + if ((string)$ext == '.png' && $output_png || (string)$ext == '.gif' && !$output_png) { return $theFile; } else { $newFile = PATH_site . 'typo3temp/readPG_' . md5(($theFile . '|' . filemtime($theFile))) . ($output_png ? '.png' : '.gif'); @@ -939,7 +939,7 @@ class GeneralUtility { * @return bool TRUE if $partStr was found to be equal to the first part of $str */ static public function isFirstPartOfStr($str, $partStr) { - return $partStr != '' && strpos((string) $str, (string) $partStr, 0) === 0; + return $partStr != '' && strpos((string)$str, (string)$partStr, 0) === 0; } /** @@ -1149,7 +1149,7 @@ class GeneralUtility { * @return string Uppercase String */ static public function strtoupper($str) { - return strtr((string) $str, 'abcdefghijklmnopqrstuvwxyz', 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'); + return strtr((string)$str, 'abcdefghijklmnopqrstuvwxyz', 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'); } /** @@ -1162,7 +1162,7 @@ class GeneralUtility { * @return string Lowercase String */ static public function strtolower($str) { - return strtr((string) $str, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz'); + return strtr((string)$str, 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz'); } /** @@ -1219,7 +1219,7 @@ class GeneralUtility { return ''; } $isStrong = NULL; - return (string) openssl_random_pseudo_bytes($bytesToGenerate, $isStrong); + return (string)openssl_random_pseudo_bytes($bytesToGenerate, $isStrong); } /** @@ -1233,7 +1233,7 @@ class GeneralUtility { if (!function_exists('mcrypt_create_iv')) { return ''; } - return (string) (@mcrypt_create_iv($bytesToGenerate, $randomSource)); + return (string)(@mcrypt_create_iv($bytesToGenerate, $randomSource)); } /** @@ -2076,19 +2076,19 @@ class GeneralUtility { // Use tag based on grand-parent + parent tag name if (isset($options['grandParentTagMap'][$stackData['grandParentTagName'] . '/' . $stackData['parentTagName']])) { $attr .= ' index="' . htmlspecialchars($tagName) . '"'; - $tagName = (string) $options['grandParentTagMap'][($stackData['grandParentTagName'] . '/' . $stackData['parentTagName'])]; + $tagName = (string)$options['grandParentTagMap'][($stackData['grandParentTagName'] . '/' . $stackData['parentTagName'])]; } elseif (isset($options['parentTagMap'][$stackData['parentTagName'] . ':_IS_NUM']) && MathUtility::canBeInterpretedAsInteger($tagName)) { // Use tag based on parent tag name + if current tag is numeric $attr .= ' index="' . htmlspecialchars($tagName) . '"'; - $tagName = (string) $options['parentTagMap'][($stackData['parentTagName'] . ':_IS_NUM')]; + $tagName = (string)$options['parentTagMap'][($stackData['parentTagName'] . ':_IS_NUM')]; } elseif (isset($options['parentTagMap'][$stackData['parentTagName'] . ':' . $tagName])) { // Use tag based on parent tag name + current tag $attr .= ' index="' . htmlspecialchars($tagName) . '"'; - $tagName = (string) $options['parentTagMap'][($stackData['parentTagName'] . ':' . $tagName)]; + $tagName = (string)$options['parentTagMap'][($stackData['parentTagName'] . ':' . $tagName)]; } elseif (isset($options['parentTagMap'][$stackData['parentTagName']])) { // Use tag based on parent tag name: $attr .= ' index="' . htmlspecialchars($tagName) . '"'; - $tagName = (string) $options['parentTagMap'][$stackData['parentTagName']]; + $tagName = (string)$options['parentTagMap'][$stackData['parentTagName']]; } elseif (MathUtility::canBeInterpretedAsInteger($tagName)) { // If integer...; if ($options['useNindex']) { @@ -2268,9 +2268,9 @@ class GeneralUtility { $current[$tagName] = base64_decode($val['value']); } else { // Had to cast it as a string - otherwise it would be evaluate FALSE if tested with isset()!! - $current[$tagName] = (string) $val['value']; + $current[$tagName] = (string)$val['value']; // Cast type: - switch ((string) $val['attributes']['type']) { + switch ((string)$val['attributes']['type']) { case 'integer': $current[$tagName] = (int)$current[$tagName]; break; @@ -2278,7 +2278,7 @@ class GeneralUtility { $current[$tagName] = (double) $current[$tagName]; break; case 'boolean': - $current[$tagName] = (bool) $current[$tagName]; + $current[$tagName] = (bool)$current[$tagName]; break; case 'NULL': $current[$tagName] = NULL; @@ -2944,7 +2944,7 @@ Connection: close $dirs = self::get_dirs($path); if ($recursivityLevels > 0 && is_array($dirs)) { foreach ($dirs as $subdirs) { - if ((string) $subdirs != '' && (!strlen($excludePattern) || !preg_match(('/^' . $excludePattern . '$/'), $subdirs))) { + if ((string)$subdirs != '' && (!strlen($excludePattern) || !preg_match(('/^' . $excludePattern . '$/'), $subdirs))) { $fileArr = self::getAllFilesAndFoldersInPath($fileArr, $path . $subdirs . '/', $extList, $regDirs, $recursivityLevels - 1, $excludePattern); } } @@ -3261,7 +3261,7 @@ Connection: close - ALSO TRY the script from the ROOT of a site (like 'http://www.mytest.com/' and not 'http://www.mytest.com/test/' !!) */ $retVal = ''; - switch ((string) $getEnvName) { + switch ((string)$getEnvName) { case 'SCRIPT_NAME': $retVal = self::isRunningOnCgiServerApi() && ($_SERVER['ORIG_PATH_INFO'] ?: $_SERVER['PATH_INFO']) @@ -3917,7 +3917,7 @@ Connection: close /** * Standard authentication code (used in Direct Mail, checkJumpUrl and setfixed links computations) * - * @param mixed $uid_or_record Uid (integer) or record (array) + * @param mixed $uid_or_record Uid (int) or record (array) * @param string $fields List of fields from the record if that is given. * @param int $codeLength Length of returned authentication code. * @return string MD5 hash of 8 chars. @@ -4694,7 +4694,7 @@ Connection: close $oldPart = $part; $partWasQuoted = $part[0] == '"'; $part = trim($part, '"'); - switch ((string) $enc) { + switch ((string)$enc) { case 'base64': $part = '=?' . $charset . '?B?' . base64_encode($part) . '?='; break; @@ -4733,7 +4733,7 @@ Connection: close * @see makeRedirectUrl() */ static public function substUrlsInPlainText($message, $urlmode = '76', $index_script_url = '') { - switch ((string) $urlmode) { + switch ((string)$urlmode) { case '': $lengthLimit = FALSE; break; @@ -5033,7 +5033,7 @@ Connection: close $valListCnt = count($valueList); foreach ($arr as $key => $value) { if (!$valListCnt || in_array($key, $valueList)) { - $str .= ((string) $key . trim((': ' . self::fixed_lgd_cs(str_replace(LF, '|', (string) $value), $valueLength)))) . '; '; + $str .= ((string)$key . trim((': ' . self::fixed_lgd_cs(str_replace(LF, '|', (string)$value), $valueLength)))) . '; '; } } return $str; diff --git a/typo3/sysext/core/Classes/Utility/MathUtility.php b/typo3/sysext/core/Classes/Utility/MathUtility.php index e61ece2894d103c102444eb767e8e53bec52ba57..2170da5bafc143244cd84d5d4cc00963c3b24b66 100644 --- a/typo3/sysext/core/Classes/Utility/MathUtility.php +++ b/typo3/sysext/core/Classes/Utility/MathUtility.php @@ -73,7 +73,7 @@ class MathUtility { if ($var === '' || is_object($var) || is_array($var)) { return FALSE; } - return (string) (int)$var === (string) $var; + return (string)(int)$var === (string)$var; } /** diff --git a/typo3/sysext/core/Classes/Utility/PathUtility.php b/typo3/sysext/core/Classes/Utility/PathUtility.php index dba5f0fd4d0543e3774fc152d2f91c06ba9fd64e..3aa668648b5607f2edcae5e7f69d76bb5d1d1167 100644 --- a/typo3/sysext/core/Classes/Utility/PathUtility.php +++ b/typo3/sysext/core/Classes/Utility/PathUtility.php @@ -51,10 +51,10 @@ class PathUtility { $resolvedTargetPath = ''; $sourcePathSteps = 0; if (strlen($sourcePath) > $commonPrefixLength) { - $resolvedSourcePath = (string) substr($sourcePath, $commonPrefixLength); + $resolvedSourcePath = (string)substr($sourcePath, $commonPrefixLength); } if (strlen($targetPath) > $commonPrefixLength) { - $resolvedTargetPath = (string) substr($targetPath, $commonPrefixLength); + $resolvedTargetPath = (string)substr($targetPath, $commonPrefixLength); } if ($resolvedSourcePath !== '') { $sourcePathSteps = count(explode('/', $resolvedSourcePath)); diff --git a/typo3/sysext/core/Classes/Utility/StringUtility.php b/typo3/sysext/core/Classes/Utility/StringUtility.php index 033914379b48bf89befeaf46d741c5913ca13336..297a7429f3de5443c1a6d005c965426bce98de05 100644 --- a/typo3/sysext/core/Classes/Utility/StringUtility.php +++ b/typo3/sysext/core/Classes/Utility/StringUtility.php @@ -49,7 +49,7 @@ class StringUtility { } $stringLength = strlen($haystack); $needleLength = strlen($needle); - return strrpos((string) $haystack, (string) $needle, 0) === $stringLength - $needleLength; + return strrpos((string)$haystack, (string)$needle, 0) === $stringLength - $needleLength; } /** diff --git a/typo3/sysext/core/Classes/Utility/VersionNumberUtility.php b/typo3/sysext/core/Classes/Utility/VersionNumberUtility.php index fa39fc82f928867bfd546a8986053010a67057bb..c468912c1d89f4a83b7ab6c1b3c55269993f0af5 100644 --- a/typo3/sysext/core/Classes/Utility/VersionNumberUtility.php +++ b/typo3/sysext/core/Classes/Utility/VersionNumberUtility.php @@ -167,7 +167,7 @@ class VersionNumberUtility { $parts[0] = MathUtility::forceIntegerInRange($parts[0], 0, 999); $parts[1] = MathUtility::forceIntegerInRange($parts[1], 0, 999); $parts[2] = MathUtility::forceIntegerInRange($parts[2], 0, 999); - switch ((string) $raise) { + switch ((string)$raise) { case 'main': $parts[0]++; $parts[1] = 0; diff --git a/typo3/sysext/core/Configuration/TCA/pages.php b/typo3/sysext/core/Configuration/TCA/pages.php index 8098a6b895f40ecdc73f5397562133da7769500f..4bfbfdc6728bf6a5bb4be24daa56f24f973519b2 100644 --- a/typo3/sysext/core/Configuration/TCA/pages.php +++ b/typo3/sysext/core/Configuration/TCA/pages.php @@ -80,12 +80,12 @@ return array( ), array( 'LLL:EXT:lang/locallang_tca.xlf:doktype.I.0', - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_DEFAULT, + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_DEFAULT, 'i/pages.gif' ), array( 'LLL:EXT:cms/locallang_tca.xlf:pages.doktype.I.4', - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_BE_USER_SECTION, + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_BE_USER_SECTION, 'i/be_users_section.gif' ), array( @@ -94,17 +94,17 @@ return array( ), array( 'LLL:EXT:cms/locallang_tca.xlf:pages.doktype.I.2', - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SHORTCUT, + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SHORTCUT, 'i/pages_shortcut.gif' ), array( 'LLL:EXT:cms/locallang_tca.xlf:pages.doktype.I.5', - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_MOUNTPOINT, + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_MOUNTPOINT, 'i/pages_mountpoint.gif' ), array( 'LLL:EXT:cms/locallang_tca.xlf:pages.doktype.I.8', - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_LINK, + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_LINK, 'i/pages_link.gif' ), array( @@ -113,21 +113,21 @@ return array( ), array( 'LLL:EXT:lang/locallang_tca.xlf:doktype.I.folder', - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SYSFOLDER, + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SYSFOLDER, 'i/sysf.gif' ), array( 'LLL:EXT:lang/locallang_tca.xlf:doktype.I.2', - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_RECYCLER, + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_RECYCLER, 'i/recycler.gif' ), array( 'LLL:EXT:cms/locallang_tca.xlf:pages.doktype.I.7', - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SPACER, + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SPACER, 'i/spacer_icon.gif' ) ), - 'default' => (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_DEFAULT, + 'default' => (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_DEFAULT, 'iconsInOptionTags' => 1, 'noIconsBelowSelect' => 1 ) @@ -822,7 +822,7 @@ return array( ), 'types' => array( // normal - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_DEFAULT => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_DEFAULT => array( 'showitem' => '--palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.standard;standard, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.title;title, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.access, @@ -849,7 +849,7 @@ return array( ' ), // external URL - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_LINK => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_LINK => array( 'showitem' => '--palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.external;external, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.title;title, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.access, @@ -872,7 +872,7 @@ return array( ' ), // shortcut - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SHORTCUT => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SHORTCUT => array( 'showitem' => '--palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.shortcut;shortcut, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.shortcutpage;shortcutpage, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.title;title, @@ -896,7 +896,7 @@ return array( ' ), // mount page - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_MOUNTPOINT => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_MOUNTPOINT => array( 'showitem' => '--palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.mountpoint;mountpoint, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.mountpage;mountpage, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.title;title, @@ -919,7 +919,7 @@ return array( ' ), // spacer - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SPACER => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SPACER => array( 'showitem' => '--palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.standard;standard, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.title;titleonly, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.access, @@ -931,7 +931,7 @@ return array( ' ), // Folder - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SYSFOLDER => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SYSFOLDER => array( 'showitem' => '--palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.standard;standard, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.title;titleonly, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.access, @@ -947,7 +947,7 @@ return array( ' ), // Trash - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_RECYCLER => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_RECYCLER => array( 'showitem' => '--palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.standard;standard, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.title;titleonly, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.access, diff --git a/typo3/sysext/core/Tests/Functional/DataHandling/IRRE/AbstractTestCase.php b/typo3/sysext/core/Tests/Functional/DataHandling/IRRE/AbstractTestCase.php index 934e6e7206975f2fca132ae285198dc83f4b9eb1..e2039faa32744c3d75a571af2d18b6cfab4fc27b 100644 --- a/typo3/sysext/core/Tests/Functional/DataHandling/IRRE/AbstractTestCase.php +++ b/typo3/sysext/core/Tests/Functional/DataHandling/IRRE/AbstractTestCase.php @@ -379,7 +379,7 @@ abstract class AbstractTestCase extends \TYPO3\CMS\Core\Tests\FunctionalTestCase if (!empty($assertion['tableName'])) { $tableName = $assertion['tableName']; unset($assertion['tableName']); - $elements = (array) $elements[$tableName]; + $elements = (array)$elements[$tableName]; } foreach ($elements as $element) { diff --git a/typo3/sysext/core/Tests/FunctionalTestCase.php b/typo3/sysext/core/Tests/FunctionalTestCase.php index ba81fb1dba489fdb3776743e9c8456e0d8ed8b1c..814a12af83546d71b9592f70ba8d886670f9b6fe 100644 --- a/typo3/sysext/core/Tests/FunctionalTestCase.php +++ b/typo3/sysext/core/Tests/FunctionalTestCase.php @@ -269,7 +269,7 @@ abstract class FunctionalTestCase extends BaseTestCase { } elseif (isset($column['is-NULL']) && ($column['is-NULL'] === 'yes')) { $columnValue = NULL; } else { - $columnValue = (string) $table->$columnName; + $columnValue = (string)$table->$columnName; } $insertArray[$columnName] = $columnValue; @@ -284,7 +284,7 @@ abstract class FunctionalTestCase extends BaseTestCase { ); } if (isset($table['id'])) { - $elementId = (string) $table['id']; + $elementId = (string)$table['id']; $foreignKeys[$tableName][$elementId] = $database->sql_insert_id(); } } diff --git a/typo3/sysext/core/Tests/Unit/Authentication/BackendUserAuthenticationTest.php b/typo3/sysext/core/Tests/Unit/Authentication/BackendUserAuthenticationTest.php index e4a77c3ce4ded50afad59d9d6ee5d6e6fc39d59b..02de2c8971e0eded54495ee5ab5939f090f82233 100644 --- a/typo3/sysext/core/Tests/Unit/Authentication/BackendUserAuthenticationTest.php +++ b/typo3/sysext/core/Tests/Unit/Authentication/BackendUserAuthenticationTest.php @@ -315,7 +315,7 @@ class BackendUserAuthenticationTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { array_walk( $expectedPermissions, function(&$value) { - $value = (bool) $value; + $value = (bool)$value; } ); diff --git a/typo3/sysext/core/Tests/Unit/Core/ApplicationContextTest.php b/typo3/sysext/core/Tests/Unit/Core/ApplicationContextTest.php index 364ae2193f2a12ceeeb6cedf8ddc0ff7a517187a..1daa158713e86163268843567102a9fa8749fff7 100644 --- a/typo3/sysext/core/Tests/Unit/Core/ApplicationContextTest.php +++ b/typo3/sysext/core/Tests/Unit/Core/ApplicationContextTest.php @@ -139,9 +139,9 @@ class ApplicationContextTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { public function parentContextIsConnectedRecursively() { $context = new ApplicationContext('Production/Foo/Bar'); $parentContext = $context->getParent(); - $this->assertSame('Production/Foo', (string) $parentContext); + $this->assertSame('Production/Foo', (string)$parentContext); $rootContext = $parentContext->getParent(); - $this->assertSame('Production', (string) $rootContext); + $this->assertSame('Production', (string)$rootContext); } } diff --git a/typo3/sysext/core/Tests/Unit/Log/LogRecordTest.php b/typo3/sysext/core/Tests/Unit/Log/LogRecordTest.php index 975d74e0235d89f4ea79a92caba11770ff25c563..672a13a963364ca62cdbf090eb9a75d68d866180 100644 --- a/typo3/sysext/core/Tests/Unit/Log/LogRecordTest.php +++ b/typo3/sysext/core/Tests/Unit/Log/LogRecordTest.php @@ -148,7 +148,7 @@ class LogRecordTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { public function toStringIncludesDataAsJson() { $dataArray = array('foo' => 'bar'); $record = $this->getRecord(array('data' => $dataArray)); - $this->assertContains(json_encode($dataArray), (string) $record); + $this->assertContains(json_encode($dataArray), (string)$record); } } diff --git a/typo3/sysext/core/Tests/Unit/Log/Writer/FileWriterTest.php b/typo3/sysext/core/Tests/Unit/Log/Writer/FileWriterTest.php index 44cb8c324b17a6e6e2e47f1daf5b0ae8decdad44..460e9cfd69571b0ac0b296fa0b2353fab9b37bf6 100644 --- a/typo3/sysext/core/Tests/Unit/Log/Writer/FileWriterTest.php +++ b/typo3/sysext/core/Tests/Unit/Log/Writer/FileWriterTest.php @@ -122,8 +122,8 @@ class FileWriterTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { $simpleRecord = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Core\\Log\\LogRecord', uniqid('test.core.log.fileWriter.simpleRecord.'), \TYPO3\CMS\Core\Log\LogLevel::INFO, 'test record'); $recordWithData = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Core\\Log\\LogRecord', uniqid('test.core.log.fileWriter.recordWithData.'), \TYPO3\CMS\Core\Log\LogLevel::ALERT, 'test record with data', array('foo' => array('bar' => 'baz'))); return array( - 'simple record' => array($simpleRecord, trim((string) $simpleRecord)), - 'record with data' => array($recordWithData, trim((string) $recordWithData)) + 'simple record' => array($simpleRecord, trim((string)$simpleRecord)), + 'record with data' => array($recordWithData, trim((string)$recordWithData)) ); } diff --git a/typo3/sysext/core/ext_tables.php b/typo3/sysext/core/ext_tables.php index ac97fa004beb8a524665928a0ee4b5efac76ded8..d039672946741e9b562f182be0cebe079ea9b36c 100644 --- a/typo3/sysext/core/ext_tables.php +++ b/typo3/sysext/core/ext_tables.php @@ -10,23 +10,23 @@ defined('TYPO3_MODE') or die(); * types, and for every type the entries simply overrides the entries in the 'default' type! */ $GLOBALS['PAGES_TYPES'] = array( - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_LINK => array(), - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SHORTCUT => array(), - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_BE_USER_SECTION => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_LINK => array(), + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SHORTCUT => array(), + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_BE_USER_SECTION => array( 'type' => 'web', 'allowedTables' => '*' ), - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_MOUNTPOINT => array(), - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SPACER => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_MOUNTPOINT => array(), + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SPACER => array( 'type' => 'sys' ), - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SYSFOLDER => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_SYSFOLDER => array( // Doktype 254 is a 'Folder' - a general purpose storage folder for whatever you like. // In CMS context it's NOT a viewable page. Can contain any element. 'type' => 'sys', 'allowedTables' => '*' ), - (string) \TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_RECYCLER => array( + (string)\TYPO3\CMS\Frontend\Page\PageRepository::DOKTYPE_RECYCLER => array( // Doktype 255 is a recycle-bin. 'type' => 'sys', 'allowedTables' => '*' diff --git a/typo3/sysext/dbal/Classes/Controller/ModuleController.php b/typo3/sysext/dbal/Classes/Controller/ModuleController.php index 5194c330db718925e2092bb943ed18ad0dd0717e..8bbda0bf73e6735bd92816e8fb7d1ee071e65c0c 100644 --- a/typo3/sysext/dbal/Classes/Controller/ModuleController.php +++ b/typo3/sysext/dbal/Classes/Controller/ModuleController.php @@ -256,7 +256,7 @@ updateQryForm(\'' . $input['QUERY'] . '\'); */ protected function printCachedInfo() { // Get cmd: - if ((string) \TYPO3\CMS\Core\Utility\GeneralUtility::_GP('cmd') === 'clear') { + if ((string)\TYPO3\CMS\Core\Utility\GeneralUtility::_GP('cmd') === 'clear') { $GLOBALS['TYPO3_DB']->clearCachedFieldInfo(); $GLOBALS['TYPO3_DB']->cacheFieldInfo(); } @@ -336,7 +336,7 @@ updateQryForm(\'' . $input['QUERY'] . '\'); // Disable debugging in any case... $GLOBALS['TYPO3_DB']->debug = FALSE; // Get cmd: - $cmd = (string) \TYPO3\CMS\Core\Utility\GeneralUtility::_GP('cmd'); + $cmd = (string)\TYPO3\CMS\Core\Utility\GeneralUtility::_GP('cmd'); switch ($cmd) { case 'flush': $res = $GLOBALS['TYPO3_DB']->exec_TRUNCATEquery('tx_dbal_debuglog'); diff --git a/typo3/sysext/dbal/Classes/Database/DatabaseConnection.php b/typo3/sysext/dbal/Classes/Database/DatabaseConnection.php index b49f0284db6477402e785cd0b83fa337e7f55e90..043a474a506af3c56b1d810225cb831c46712b7e 100644 --- a/typo3/sysext/dbal/Classes/Database/DatabaseConnection.php +++ b/typo3/sysext/dbal/Classes/Database/DatabaseConnection.php @@ -628,7 +628,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { } // Select API $this->lastHandlerKey = $this->handler_getFromTableList($table); - $hType = (string) $this->handlerCfg[$this->lastHandlerKey]['type']; + $hType = (string)$this->handlerCfg[$this->lastHandlerKey]['type']; $sqlResult = NULL; switch ($hType) { case 'native': @@ -709,7 +709,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { } // Select API $this->lastHandlerKey = $this->handler_getFromTableList($table); - $hType = (string) $this->handlerCfg[$this->lastHandlerKey]['type']; + $hType = (string)$this->handlerCfg[$this->lastHandlerKey]['type']; $sqlResult = NULL; switch ($hType) { case 'native': @@ -772,7 +772,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { $fromTable = $from_table; } $this->lastHandlerKey = $this->handler_getFromTableList($fromTable); - $hType = (string) $this->handlerCfg[$this->lastHandlerKey]['type']; + $hType = (string)$this->handlerCfg[$this->lastHandlerKey]['type']; $sqlResult = NULL; switch ($hType) { case 'native': @@ -861,7 +861,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { } // Select API $this->lastHandlerKey = $this->handler_getFromTableList($table); - $hType = (string) $this->handlerCfg[$this->lastHandlerKey]['type']; + $hType = (string)$this->handlerCfg[$this->lastHandlerKey]['type']; $sqlResult = NULL; switch ($hType) { case 'native': @@ -1056,7 +1056,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { * @return string|array Full SQL query for INSERT (unless $rows does not contain any elements in which case it will be FALSE) */ public function INSERTmultipleRows($table, array $fields, array $rows, $no_quote_fields = FALSE) { - if ((string) $this->handlerCfg[$this->lastHandlerKey]['type'] === 'native') { + if ((string)$this->handlerCfg[$this->lastHandlerKey]['type'] === 'native') { return parent::INSERTmultipleRows($table, $fields, $rows, $no_quote_fields); } $result = array(); @@ -1196,7 +1196,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { */ public function SELECTquery($select_fields, $from_table, $where_clause, $groupBy = '', $orderBy = '', $limit = '') { $this->lastHandlerKey = $this->handler_getFromTableList($from_table); - $hType = (string) $this->handlerCfg[$this->lastHandlerKey]['type']; + $hType = (string)$this->handlerCfg[$this->lastHandlerKey]['type']; if ($hType === 'adodb' && $this->runningADOdbDriver('postgres')) { // Possibly rewrite the LIMIT to be PostgreSQL-compatible $splitLimit = GeneralUtility::intExplode(',', $limit); @@ -1408,7 +1408,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { 'parameters' => array() ); $this->lastHandlerKey = $this->handler_getFromTableList($from_table); - $hType = (string) $this->handlerCfg[$this->lastHandlerKey]['type']; + $hType = (string)$this->handlerCfg[$this->lastHandlerKey]['type']; if ($hType === 'adodb' && $this->runningADOdbDriver('postgres')) { // Possibly rewrite the LIMIT to be PostgreSQL-compatible $splitLimit = GeneralUtility::intExplode(',', $limit); @@ -1461,7 +1461,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { $limit = $components['LIMIT']; $precompiledParts = array(); $this->lastHandlerKey = $this->handler_getFromTableList($components['ORIG_tableName']); - $hType = (string) $this->handlerCfg[$this->lastHandlerKey]['type']; + $hType = (string)$this->handlerCfg[$this->lastHandlerKey]['type']; $precompiledParts['handler'] = $hType; $precompiledParts['ORIG_tableName'] = $components['ORIG_tableName']; switch ($hType) { @@ -1938,7 +1938,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { public function MetaType($type, $table, $maxLength = -1) { $this->lastHandlerKey = $this->handler_getFromTableList($table); $str = ''; - switch ((string) $this->handlerCfg[$this->lastHandlerKey]['type']) { + switch ((string)$this->handlerCfg[$this->lastHandlerKey]['type']) { case 'native': $str = $type; break; @@ -2682,7 +2682,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { } // Find columns $this->lastHandlerKey = $this->handler_getFromTableList($tableName); - switch ((string) $this->handlerCfg[$this->lastHandlerKey]['type']) { + switch ((string)$this->handlerCfg[$this->lastHandlerKey]['type']) { case 'native': /** @var \mysqli_result $columns_res */ $columns_res = $this->query('SHOW columns FROM ' . $tableName); @@ -2747,7 +2747,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { } // Find columns $this->lastHandlerKey = $this->handler_getFromTableList($tableName); - switch ((string) $this->handlerCfg[$this->lastHandlerKey]['type']) { + switch ((string)$this->handlerCfg[$this->lastHandlerKey]['type']) { case 'native': /** @var \mysqli_result $keyRes */ $keyRes = $this->query('SHOW keys FROM ' . $tableName); @@ -3115,7 +3115,7 @@ class DatabaseConnection extends \TYPO3\CMS\Core\Database\DatabaseConnection { */ public function isConnected() { $result = FALSE; - switch ((string) $this->handlerCfg[$this->lastHandlerKey]['type']) { + switch ((string)$this->handlerCfg[$this->lastHandlerKey]['type']) { case 'native': $result = isset($this->handlerCfg[$this->lastHandlerKey]['link']); break; diff --git a/typo3/sysext/extbase/Classes/Configuration/ConfigurationManager.php b/typo3/sysext/extbase/Classes/Configuration/ConfigurationManager.php index 7ed5dcce686161cfd27b6f97b63c024b95edd78d..eb5e0f8f02e2e5617ceefe6d52875b979ed303e9 100644 --- a/typo3/sysext/extbase/Classes/Configuration/ConfigurationManager.php +++ b/typo3/sysext/extbase/Classes/Configuration/ConfigurationManager.php @@ -127,6 +127,6 @@ class ConfigurationManager implements \TYPO3\CMS\Extbase\Configuration\Configura */ public function isFeatureEnabled($featureName) { $configuration = $this->getConfiguration(self::CONFIGURATION_TYPE_FRAMEWORK); - return (boolean) (isset($configuration['features'][$featureName]) && $configuration['features'][$featureName]); + return (bool)(isset($configuration['features'][$featureName]) && $configuration['features'][$featureName]); } } diff --git a/typo3/sysext/extbase/Classes/DomainObject/AbstractDomainObject.php b/typo3/sysext/extbase/Classes/DomainObject/AbstractDomainObject.php index 098d7fe017c3dd8680f1a9d414857e669ccdce57..4573b665c3ec2a94b345d8d798b7e737b7f5b2da 100644 --- a/typo3/sysext/extbase/Classes/DomainObject/AbstractDomainObject.php +++ b/typo3/sysext/extbase/Classes/DomainObject/AbstractDomainObject.php @@ -307,7 +307,7 @@ abstract class AbstractDomainObject implements DomainObjectInterface, \TYPO3\CMS * @param bool $clone */ public function _setClone($clone) { - $this->_isClone = (boolean) $clone; + $this->_isClone = (bool)$clone; } /** @@ -325,6 +325,6 @@ abstract class AbstractDomainObject implements DomainObjectInterface, \TYPO3\CMS * @return string */ public function __toString() { - return get_class($this) . ':' . (string) $this->uid; + return get_class($this) . ':' . (string)$this->uid; } } diff --git a/typo3/sysext/extbase/Classes/Mvc/Controller/AbstractController.php b/typo3/sysext/extbase/Classes/Mvc/Controller/AbstractController.php index fd8d5efa27ba084bcab1bccd255baff87b4c4030..23411bd839bf168513e8700afab068973795e943 100644 --- a/typo3/sysext/extbase/Classes/Mvc/Controller/AbstractController.php +++ b/typo3/sysext/extbase/Classes/Mvc/Controller/AbstractController.php @@ -327,7 +327,7 @@ abstract class AbstractController implements ControllerInterface { $this->response->setContent('<html><head><meta http-equiv="refresh" content="' . (int)$delay . ';url=' . $escapedUri . '"/></head></html>'); if ($this->response instanceof \TYPO3\CMS\Extbase\Mvc\Web\Response) { $this->response->setStatus($statusCode); - $this->response->setHeader('Location', (string) $uri); + $this->response->setHeader('Location', (string)$uri); } throw new StopActionException(); } @@ -339,7 +339,7 @@ abstract class AbstractController implements ControllerInterface { * @return string */ protected function addBaseUriIfNecessary($uri) { - return \TYPO3\CMS\Core\Utility\GeneralUtility::locationHeaderUrl((string) $uri); + return \TYPO3\CMS\Core\Utility\GeneralUtility::locationHeaderUrl((string)$uri); } /** diff --git a/typo3/sysext/extbase/Classes/Mvc/Controller/Argument.php b/typo3/sysext/extbase/Classes/Mvc/Controller/Argument.php index 9578581475aae7929dc041deea4f9fd4d7872310..1d259a7e191ba3ced631926b36d7e62ecd189b58 100644 --- a/typo3/sysext/extbase/Classes/Mvc/Controller/Argument.php +++ b/typo3/sysext/extbase/Classes/Mvc/Controller/Argument.php @@ -163,7 +163,7 @@ class Argument { * @api */ public function setRequired($required) { - $this->isRequired = (boolean) $required; + $this->isRequired = (bool)$required; return $this; } @@ -294,6 +294,6 @@ class Argument { * @api */ public function __toString() { - return (string) $this->value; + return (string)$this->value; } } diff --git a/typo3/sysext/extbase/Classes/Mvc/Controller/CommandController.php b/typo3/sysext/extbase/Classes/Mvc/Controller/CommandController.php index f2f585cc0ba4cab9f6dd5f5aaa326c6ed92423af..3975d48cd64398fb151b16b0e23c7ea4407c8cbb 100644 --- a/typo3/sysext/extbase/Classes/Mvc/Controller/CommandController.php +++ b/typo3/sysext/extbase/Classes/Mvc/Controller/CommandController.php @@ -215,7 +215,7 @@ class CommandController implements CommandControllerInterface { if (is_string($commandResult) && strlen($commandResult) > 0) { $this->response->appendContent($commandResult); } elseif (is_object($commandResult) && method_exists($commandResult, '__toString')) { - $this->response->appendContent((string) $commandResult); + $this->response->appendContent((string)$commandResult); } } diff --git a/typo3/sysext/extbase/Classes/Mvc/Web/Request.php b/typo3/sysext/extbase/Classes/Mvc/Web/Request.php index e7f8b0cd5273afae9f433eff9852d749d9a43b82..fb593c673d79690fdf073419ff8afb1dc9189a47 100644 --- a/typo3/sysext/extbase/Classes/Mvc/Web/Request.php +++ b/typo3/sysext/extbase/Classes/Mvc/Web/Request.php @@ -137,7 +137,7 @@ class Request extends \TYPO3\CMS\Extbase\Mvc\Request { * @param bool $isCached */ public function setIsCached($isCached) { - $this->isCached = (boolean) $isCached; + $this->isCached = (bool)$isCached; } /** diff --git a/typo3/sysext/extbase/Classes/Mvc/Web/RequestBuilder.php b/typo3/sysext/extbase/Classes/Mvc/Web/RequestBuilder.php index d49323ac5ca33981947b7156730418f1ef8dc45f..ad426c839f92f421498d81bfcd4716ec78fb8164 100644 --- a/typo3/sysext/extbase/Classes/Mvc/Web/RequestBuilder.php +++ b/typo3/sysext/extbase/Classes/Mvc/Web/RequestBuilder.php @@ -175,9 +175,9 @@ class RequestBuilder implements \TYPO3\CMS\Core\SingletonInterface { $allowedControllerNames = array_keys($this->allowedControllerActions); if (!in_array($parameters['controller'], $allowedControllerNames)) { $configuration = $this->configurationManager->getConfiguration(ConfigurationManagerInterface::CONFIGURATION_TYPE_FRAMEWORK); - if (isset($configuration['mvc']['throwPageNotFoundExceptionIfActionCantBeResolved']) && (boolean) $configuration['mvc']['throwPageNotFoundExceptionIfActionCantBeResolved']) { + if (isset($configuration['mvc']['throwPageNotFoundExceptionIfActionCantBeResolved']) && (bool)$configuration['mvc']['throwPageNotFoundExceptionIfActionCantBeResolved']) { throw new \TYPO3\CMS\Core\Error\Http\PageNotFoundException('The requested resource was not found', 1313857897); - } elseif (isset($configuration['mvc']['callDefaultActionIfActionCantBeResolved']) && (boolean) $configuration['mvc']['callDefaultActionIfActionCantBeResolved']) { + } elseif (isset($configuration['mvc']['callDefaultActionIfActionCantBeResolved']) && (bool)$configuration['mvc']['callDefaultActionIfActionCantBeResolved']) { return $this->defaultControllerName; } throw new \TYPO3\CMS\Extbase\Mvc\Exception\InvalidControllerNameException('The controller "' . $parameters['controller'] . '" is not allowed by this plugin. Please check for TYPO3\\CMS\\Extbase\\Utility\\ExtensionUtility::configurePlugin() in your ext_localconf.php.', 1313855173); @@ -209,9 +209,9 @@ class RequestBuilder implements \TYPO3\CMS\Core\SingletonInterface { $allowedActionNames = $this->allowedControllerActions[$controllerName]; if (!in_array($actionName, $allowedActionNames)) { $configuration = $this->configurationManager->getConfiguration(ConfigurationManagerInterface::CONFIGURATION_TYPE_FRAMEWORK); - if (isset($configuration['mvc']['throwPageNotFoundExceptionIfActionCantBeResolved']) && (boolean) $configuration['mvc']['throwPageNotFoundExceptionIfActionCantBeResolved']) { + if (isset($configuration['mvc']['throwPageNotFoundExceptionIfActionCantBeResolved']) && (bool)$configuration['mvc']['throwPageNotFoundExceptionIfActionCantBeResolved']) { throw new \TYPO3\CMS\Core\Error\Http\PageNotFoundException('The requested resource was not found', 1313857898); - } elseif (isset($configuration['mvc']['callDefaultActionIfActionCantBeResolved']) && (boolean) $configuration['mvc']['callDefaultActionIfActionCantBeResolved']) { + } elseif (isset($configuration['mvc']['callDefaultActionIfActionCantBeResolved']) && (bool)$configuration['mvc']['callDefaultActionIfActionCantBeResolved']) { return $defaultActionName; } throw new \TYPO3\CMS\Extbase\Mvc\Exception\InvalidActionNameException('The action "' . $actionName . '" (controller "' . $controllerName . '") is not allowed by this plugin. Please check TYPO3\\CMS\\Extbase\\Utility\\ExtensionUtility::configurePlugin() in your ext_localconf.php.', 1313855175); diff --git a/typo3/sysext/extbase/Classes/Mvc/Web/Routing/UriBuilder.php b/typo3/sysext/extbase/Classes/Mvc/Web/Routing/UriBuilder.php index 5305a245da1faf30685e138cb8faa39177303542..9f8aed08d7115fada62fbfb3f6156099aebbf00e 100644 --- a/typo3/sysext/extbase/Classes/Mvc/Web/Routing/UriBuilder.php +++ b/typo3/sysext/extbase/Classes/Mvc/Web/Routing/UriBuilder.php @@ -265,7 +265,7 @@ class UriBuilder { * @see TSref/typolink.addQueryString */ public function setAddQueryString($addQueryString) { - $this->addQueryString = (boolean) $addQueryString; + $this->addQueryString = (bool)$addQueryString; return $this; } @@ -329,7 +329,7 @@ class UriBuilder { * @return \TYPO3\CMS\Extbase\Mvc\Web\Routing\UriBuilder the current UriBuilder to allow method chaining */ public function setArgumentPrefix($argumentPrefix) { - $this->argumentPrefix = (string) $argumentPrefix; + $this->argumentPrefix = (string)$argumentPrefix; return $this; } @@ -348,7 +348,7 @@ class UriBuilder { * @api */ public function setLinkAccessRestrictedPages($linkAccessRestrictedPages) { - $this->linkAccessRestrictedPages = (boolean) $linkAccessRestrictedPages; + $this->linkAccessRestrictedPages = (bool)$linkAccessRestrictedPages; return $this; } @@ -410,7 +410,7 @@ class UriBuilder { * @api */ public function setNoCache($noCache) { - $this->noCache = (boolean) $noCache; + $this->noCache = (bool)$noCache; return $this; } @@ -431,7 +431,7 @@ class UriBuilder { * @api */ public function setUseCacheHash($useCacheHash) { - $this->useCacheHash = (boolean) $useCacheHash; + $this->useCacheHash = (bool)$useCacheHash; return $this; } diff --git a/typo3/sysext/extbase/Classes/Property/TypeConverter/BooleanConverter.php b/typo3/sysext/extbase/Classes/Property/TypeConverter/BooleanConverter.php index 70b736db39821133f72801a5890755efaa86ad34..3558560443417a5066c06d37d30a2e7220b6189d 100644 --- a/typo3/sysext/extbase/Classes/Property/TypeConverter/BooleanConverter.php +++ b/typo3/sysext/extbase/Classes/Property/TypeConverter/BooleanConverter.php @@ -53,6 +53,6 @@ class BooleanConverter extends \TYPO3\CMS\Extbase\Property\TypeConverter\Abstrac * @api */ public function convertFrom($source, $targetType, array $convertedChildProperties = array(), \TYPO3\CMS\Extbase\Property\PropertyMappingConfigurationInterface $configuration = NULL) { - return (boolean) $source; + return (bool)$source; } } diff --git a/typo3/sysext/extbase/Classes/Property/TypeConverter/StringConverter.php b/typo3/sysext/extbase/Classes/Property/TypeConverter/StringConverter.php index f21a76e33760fc3c6b7f9bc81dd3becfc010b904..539362e0ae8ffae5bf323479485b13cd68db4508 100644 --- a/typo3/sysext/extbase/Classes/Property/TypeConverter/StringConverter.php +++ b/typo3/sysext/extbase/Classes/Property/TypeConverter/StringConverter.php @@ -54,6 +54,6 @@ class StringConverter extends \TYPO3\CMS\Extbase\Property\TypeConverter\Abstract * @api */ public function convertFrom($source, $targetType, array $convertedChildProperties = array(), \TYPO3\CMS\Extbase\Property\PropertyMappingConfigurationInterface $configuration = NULL) { - return (string) $source; + return (string)$source; } } diff --git a/typo3/sysext/extbase/Classes/Scheduler/FieldProvider.php b/typo3/sysext/extbase/Classes/Scheduler/FieldProvider.php index 125b0ee78d6099e974fa66e0ff8719260a27f8e1..2c04d9c506ec35405d7c6c10b052ab4e37a597f5 100644 --- a/typo3/sysext/extbase/Classes/Scheduler/FieldProvider.php +++ b/typo3/sysext/extbase/Classes/Scheduler/FieldProvider.php @@ -97,7 +97,7 @@ class FieldProvider implements \TYPO3\CMS\Scheduler\AdditionalFieldProviderInter */ public function saveAdditionalFields(array $submittedData, \TYPO3\CMS\Scheduler\Task\AbstractTask $task) { $task->setCommandIdentifier($submittedData['task_extbase']['action']); - $task->setArguments((array) $submittedData['task_extbase']['arguments']); + $task->setArguments((array)$submittedData['task_extbase']['arguments']); return TRUE; } @@ -252,7 +252,7 @@ class FieldProvider implements \TYPO3\CMS\Scheduler\AdditionalFieldProviderInter $argumentReflection = $this->reflectionService->getMethodParameters($command->getControllerClassName(), $command->getControllerCommandName() . 'Command'); $defaultValue = $argumentReflection[$argumentName]['defaultValue']; if ($type === 'boolean') { - $defaultValue = (boolean) $defaultValue ? 1 : 0; + $defaultValue = (bool)$defaultValue ? 1 : 0; } return $defaultValue; } @@ -305,7 +305,7 @@ class FieldProvider implements \TYPO3\CMS\Scheduler\AdditionalFieldProviderInter if ($type === 'boolean') { // checkbox field for boolean values. $html = '<input type="hidden" name="' . $fieldName . '" value="0" />'; - $html .= '<input type="checkbox" name="' . $fieldName . '" value="1" ' . ((boolean) $currentValue ? ' checked="checked"' : '') . '/>'; + $html .= '<input type="checkbox" name="' . $fieldName . '" value="1" ' . ((bool)$currentValue ? ' checked="checked"' : '') . '/>'; } else { // regular string, also the default field type $html = '<input type="text" name="' . $fieldName . '" value="' . htmlspecialchars($currentValue) . '" /> '; diff --git a/typo3/sysext/extbase/Classes/Service/CacheService.php b/typo3/sysext/extbase/Classes/Service/CacheService.php index 01bcf38e7ff3b52238ff2b48f94e914f97b6d8ba..9fafacd91cd550e05f22ebc9bd97a2db2b7fc435 100644 --- a/typo3/sysext/extbase/Classes/Service/CacheService.php +++ b/typo3/sysext/extbase/Classes/Service/CacheService.php @@ -53,7 +53,7 @@ class CacheService implements \TYPO3\CMS\Core\SingletonInterface { /** * Clears the page cache * - * @param mixed $pageIdsToClear (integer) single or (array) multiple pageIds to clear the cache for + * @param mixed $pageIdsToClear (int) single or (array) multiple pageIds to clear the cache for * @return void */ public function clearPageCache($pageIdsToClear = NULL) { diff --git a/typo3/sysext/extbase/Classes/Utility/ArrayUtility.php b/typo3/sysext/extbase/Classes/Utility/ArrayUtility.php index 779b4869982d2ff4d8142f087018a60bee22768a..8309bed1eb091e29805414f86fe71ce73a735e35 100644 --- a/typo3/sysext/extbase/Classes/Utility/ArrayUtility.php +++ b/typo3/sysext/extbase/Classes/Utility/ArrayUtility.php @@ -272,7 +272,7 @@ class ArrayUtility { throw new \InvalidArgumentException('convertObjectToArray expects either array or object as input, ' . gettype($subject) . ' given.', 1287059709); } if (is_object($subject)) { - $subject = (array) $subject; + $subject = (array)$subject; } foreach ($subject as $key => $value) { if (is_array($value) || is_object($value)) { diff --git a/typo3/sysext/extbase/Tests/Functional/Fixtures/Extensions/blog_example/Classes/Domain/Repository/PostRepository.php b/typo3/sysext/extbase/Tests/Functional/Fixtures/Extensions/blog_example/Classes/Domain/Repository/PostRepository.php index a55f678cd8f36bd80429cb1da580ed389d74666e..00f7b91136827ca356e700c17060828137ff4e59 100644 --- a/typo3/sysext/extbase/Tests/Functional/Fixtures/Extensions/blog_example/Classes/Domain/Repository/PostRepository.php +++ b/typo3/sysext/extbase/Tests/Functional/Fixtures/Extensions/blog_example/Classes/Domain/Repository/PostRepository.php @@ -120,7 +120,7 @@ class PostRepository extends \TYPO3\CMS\Extbase\Persistence\Repository { ->matching( $query->equals('blog', $blog) ) - ->setLimit((integer)$limit) + ->setLimit((int)$limit) ->execute(); } diff --git a/typo3/sysext/extbase/Tests/Unit/Mvc/ResponseTest.php b/typo3/sysext/extbase/Tests/Unit/Mvc/ResponseTest.php index aa73c989a3c78b844ded75f259cca42f67678ff1..b23685a968987a5beec1f04f5641cc47bc82abbe 100644 --- a/typo3/sysext/extbase/Tests/Unit/Mvc/ResponseTest.php +++ b/typo3/sysext/extbase/Tests/Unit/Mvc/ResponseTest.php @@ -65,6 +65,6 @@ class ResponseTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { */ public function __toStringReturnsActualContent() { $this->mockResponse->_set('content', 'foo'); - $this->assertSame('foo', (string) $this->mockResponse); + $this->assertSame('foo', (string)$this->mockResponse); } } diff --git a/typo3/sysext/extbase/Tests/Unit/Persistence/Generic/Mapper/DataMapFactoryTest.php b/typo3/sysext/extbase/Tests/Unit/Persistence/Generic/Mapper/DataMapFactoryTest.php index 10e59f6d26abffbc8942553f3500560670e2b94f..e719c2b519d97ea9d02715c329690b744a75a3b9 100644 --- a/typo3/sysext/extbase/Tests/Unit/Persistence/Generic/Mapper/DataMapFactoryTest.php +++ b/typo3/sysext/extbase/Tests/Unit/Persistence/Generic/Mapper/DataMapFactoryTest.php @@ -489,7 +489,7 @@ class DataMapFactoryTest extends \TYPO3\CMS\Core\Tests\UnitTestCase { $dataMapFactory->_call('setType', $columnMap, $columnConfiguration); - $this->assertEquals($type, (string) $columnMap->getType()); - $this->assertEquals($internalType, (string) $columnMap->getInternalType()); + $this->assertEquals($type, (string)$columnMap->getType()); + $this->assertEquals($internalType, (string)$columnMap->getInternalType()); } } diff --git a/typo3/sysext/extensionmanager/Classes/Utility/EmConfUtility.php b/typo3/sysext/extensionmanager/Classes/Utility/EmConfUtility.php index 197cd3b947694655d5dad693f86d2c5eb97d5b8a..ee3ddf3ad1d4bd6cef916760d258206af78d255c 100644 --- a/typo3/sysext/extensionmanager/Classes/Utility/EmConfUtility.php +++ b/typo3/sysext/extensionmanager/Classes/Utility/EmConfUtility.php @@ -122,8 +122,8 @@ $EM_CONF[$_EXTKEY] = ' . $emConf . '; } /** - * Checks whether the passed dependency is TER-style (string) or - * TER2-style (array) and returns a single string for displaying the + * Checks whether the passed dependency is TER-style (string)or + * TER2-style (array)and returns a single string for displaying the * dependencies. * * It leaves out all version numbers and the "php" and "typo3" dependencies, diff --git a/typo3/sysext/extensionmanager/Classes/Utility/FileHandlingUtility.php b/typo3/sysext/extensionmanager/Classes/Utility/FileHandlingUtility.php index 25cb7862e66c8110be1ec3e6241bbc66e66f40a1..c7b6763a0c83984658bcb3fbfa9bf65f9bfe23af 100644 --- a/typo3/sysext/extensionmanager/Classes/Utility/FileHandlingUtility.php +++ b/typo3/sysext/extensionmanager/Classes/Utility/FileHandlingUtility.php @@ -230,7 +230,7 @@ class FileHandlingUtility implements \TYPO3\CMS\Core\SingletonInterface { */ protected function getAbsolutePathsToConfiguredDirectories(array $extension) { $requestedDirectories = array(); - $requestUploadFolder = isset($extension['uploadfolder']) ? (boolean)$extension['uploadfolder'] : FALSE; + $requestUploadFolder = isset($extension['uploadfolder']) ? (bool)$extension['uploadfolder'] : FALSE; if ($requestUploadFolder) { $requestedDirectories[] = $this->getAbsolutePath($this->getPathToUploadFolder($extension)); } diff --git a/typo3/sysext/extensionmanager/Classes/Utility/InstallUtility.php b/typo3/sysext/extensionmanager/Classes/Utility/InstallUtility.php index ad6e83cce95cd281a141bacaf0a4dc388a329e02..e9d5a23d9c5bdeadae6d46d1f7f87ed9867ea07a 100644 --- a/typo3/sysext/extensionmanager/Classes/Utility/InstallUtility.php +++ b/typo3/sysext/extensionmanager/Classes/Utility/InstallUtility.php @@ -308,13 +308,13 @@ class InstallUtility implements \TYPO3\CMS\Core\SingletonInterface { $diff = $this->installToolSqlParser->getDatabaseExtra($fieldDefinitionsFromFile, $fieldDefinitionsFromCurrentDatabase); $updateStatements = $this->installToolSqlParser->getUpdateSuggestions($diff); $db = $this->getDatabaseConnection(); - foreach ((array) $updateStatements['add'] as $string) { + foreach ((array)$updateStatements['add'] as $string) { $db->admin_query($string); } - foreach ((array) $updateStatements['change'] as $string) { + foreach ((array)$updateStatements['change'] as $string) { $db->admin_query($string); } - foreach ((array) $updateStatements['create_table'] as $string) { + foreach ((array)$updateStatements['create_table'] as $string) { $db->admin_query($string); } } diff --git a/typo3/sysext/extensionmanager/Classes/Utility/Parser/AbstractXmlParser.php b/typo3/sysext/extensionmanager/Classes/Utility/Parser/AbstractXmlParser.php index 9d267f6421197e107504c0aee388124bd13b0a21..5aed95e75132620fd6e73cc0049cbbfa17b80d82 100644 --- a/typo3/sysext/extensionmanager/Classes/Utility/Parser/AbstractXmlParser.php +++ b/typo3/sysext/extensionmanager/Classes/Utility/Parser/AbstractXmlParser.php @@ -94,7 +94,7 @@ abstract class AbstractXmlParser implements \SplSubject { $isAvailable = TRUE; if (!extension_loaded($this->requiredPhpExtensions)) { $prefix = PHP_SHLIB_SUFFIX === 'dll' ? 'php_' : ''; - if (!(((bool) ini_get('enable_dl') && !(bool) ini_get('safe_mode')) && function_exists('dl') && dl($prefix . $this->requiredPhpExtensions . PHP_SHLIB_SUFFIX))) { + if (!(((bool)ini_get('enable_dl') && !(bool)ini_get('safe_mode')) && function_exists('dl') && dl($prefix . $this->requiredPhpExtensions . PHP_SHLIB_SUFFIX))) { $isAvailable = FALSE; } } diff --git a/typo3/sysext/fluid/Classes/Core/Parser/SyntaxTree/AbstractNode.php b/typo3/sysext/fluid/Classes/Core/Parser/SyntaxTree/AbstractNode.php index 75999c4a08c36b1f14fbdbd5a039b86ec63ebd6a..26b5b5d3c02a50912d9559265fc42ca638245243 100644 --- a/typo3/sysext/fluid/Classes/Core/Parser/SyntaxTree/AbstractNode.php +++ b/typo3/sysext/fluid/Classes/Core/Parser/SyntaxTree/AbstractNode.php @@ -42,7 +42,7 @@ abstract class AbstractNode implements \TYPO3\CMS\Fluid\Core\Parser\SyntaxTree\N } $output = $output->__toString(); } else { - $output = (string) $output; + $output = (string)$output; } $subNodeOutput = $subNode->evaluate($renderingContext); @@ -52,7 +52,7 @@ abstract class AbstractNode implements \TYPO3\CMS\Fluid\Core\Parser\SyntaxTree\N } $output .= $subNodeOutput->__toString(); } else { - $output .= (string) $subNodeOutput; + $output .= (string)$subNodeOutput; } } } diff --git a/typo3/sysext/fluid/Classes/Core/Parser/SyntaxTree/BooleanNode.php b/typo3/sysext/fluid/Classes/Core/Parser/SyntaxTree/BooleanNode.php index f9773fcf476c414eb08b11806490e3f77aa8949c..3378ed2dba039150a0259f5382f2fc5b57bd26f9 100644 --- a/typo3/sysext/fluid/Classes/Core/Parser/SyntaxTree/BooleanNode.php +++ b/typo3/sysext/fluid/Classes/Core/Parser/SyntaxTree/BooleanNode.php @@ -234,7 +234,7 @@ class BooleanNode extends \TYPO3\CMS\Fluid\Core\Parser\SyntaxTree\AbstractNode { if (!self::isComparable($evaluatedLeftSide, $evaluatedRightSide)) { return FALSE; } - return (boolean) ((int)$evaluatedLeftSide % (int)$evaluatedRightSide); + return (bool)((int)$evaluatedLeftSide % (int)$evaluatedRightSide); case '>': if (!self::isComparable($evaluatedLeftSide, $evaluatedRightSide)) { return FALSE; @@ -331,7 +331,7 @@ class BooleanNode extends \TYPO3\CMS\Fluid\Core\Parser\SyntaxTree\AbstractNode { return (!empty($value) && strtolower($value) !== 'false'); } if (is_array($value) || (is_object($value) && $value instanceof \Countable)) { - return (bool) count($value); + return (bool)count($value); } if (is_object($value)) { return TRUE; diff --git a/typo3/sysext/fluid/Classes/Core/Parser/TemplateParser.php b/typo3/sysext/fluid/Classes/Core/Parser/TemplateParser.php index 7a2dfbd164801da069f8642004e5ec2931df6df0..b5e44821ae038456e87d0054622e3b599cee7a97 100644 --- a/typo3/sysext/fluid/Classes/Core/Parser/TemplateParser.php +++ b/typo3/sysext/fluid/Classes/Core/Parser/TemplateParser.php @@ -710,7 +710,7 @@ class TemplateParser { protected function postProcessArgumentsForObjectAccessor(array $arguments) { foreach ($arguments as $argumentName => $argumentValue) { if (!($argumentValue instanceof \TYPO3\CMS\Fluid\Core\Parser\SyntaxTree\AbstractNode)) { - $arguments[$argumentName] = $this->objectManager->get('TYPO3\\CMS\\Fluid\\Core\\Parser\\SyntaxTree\\TextNode', (string) $argumentValue); + $arguments[$argumentName] = $this->objectManager->get('TYPO3\\CMS\\Fluid\\Core\\Parser\\SyntaxTree\\TextNode', (string)$argumentValue); } } return $arguments; diff --git a/typo3/sysext/fluid/Classes/Service/DocbookGenerator.php b/typo3/sysext/fluid/Classes/Service/DocbookGenerator.php index 5691a8a0fb6b6a294738c16d3ba0557263edad42..add04252b1579022cbcf46c5eaf910b1cc8319ee 100644 --- a/typo3/sysext/fluid/Classes/Service/DocbookGenerator.php +++ b/typo3/sysext/fluid/Classes/Service/DocbookGenerator.php @@ -122,7 +122,7 @@ class DocbookGenerator extends \TYPO3\CMS\Fluid\Service\AbstractGenerator { $row->addChild('entry', $type); $row->addChild('entry', $required); $row->addChild('entry', $description); - $row->addChild('entry', (string) $default); + $row->addChild('entry', (string)$default); } /** diff --git a/typo3/sysext/fluid/Classes/ViewHelpers/CObjectViewHelper.php b/typo3/sysext/fluid/Classes/ViewHelpers/CObjectViewHelper.php index 755459567a3e8abdfb6777a5847a7a8419e12625..09ca03250e9496be18bc922e6eb04641e4d327a8 100644 --- a/typo3/sysext/fluid/Classes/ViewHelpers/CObjectViewHelper.php +++ b/typo3/sysext/fluid/Classes/ViewHelpers/CObjectViewHelper.php @@ -94,7 +94,7 @@ class CObjectViewHelper extends \TYPO3\CMS\Fluid\Core\ViewHelper\AbstractViewHel if (is_object($data)) { $data = \TYPO3\CMS\Extbase\Reflection\ObjectAccess::getGettableProperties($data); } elseif (is_string($data) || is_numeric($data)) { - $currentValue = (string) $data; + $currentValue = (string)$data; $data = array($data); } /** @var \TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer $contentObject */ diff --git a/typo3/sysext/fluid/Classes/ViewHelpers/DebugViewHelper.php b/typo3/sysext/fluid/Classes/ViewHelpers/DebugViewHelper.php index 844528e762570abdd6983169269e83c932c5c7b7..ecf551c45dc172c7409bbb3e4c4eb22da7e1b85c 100644 --- a/typo3/sysext/fluid/Classes/ViewHelpers/DebugViewHelper.php +++ b/typo3/sysext/fluid/Classes/ViewHelpers/DebugViewHelper.php @@ -47,6 +47,6 @@ class DebugViewHelper extends \TYPO3\CMS\Fluid\Core\ViewHelper\AbstractViewHelpe * @return string */ public function render($title = NULL, $maxDepth = 8, $plainText = FALSE, $ansiColors = FALSE, $inline = FALSE, $blacklistedClassNames = NULL, $blacklistedPropertyNames = NULL) { - return \TYPO3\CMS\Extbase\Utility\DebuggerUtility::var_dump($this->renderChildren(), $title, $maxDepth, (boolean) $plainText, (boolean) $ansiColors, (boolean) $inline, $blacklistedClassNames, $blacklistedPropertyNames); + return \TYPO3\CMS\Extbase\Utility\DebuggerUtility::var_dump($this->renderChildren(), $title, $maxDepth, (bool)$plainText, (bool)$ansiColors, (bool)$inline, $blacklistedClassNames, $blacklistedPropertyNames); } } diff --git a/typo3/sysext/fluid/Classes/ViewHelpers/Form/AbstractFormViewHelper.php b/typo3/sysext/fluid/Classes/ViewHelpers/Form/AbstractFormViewHelper.php index 9b72dd144a5cbb3625394ae580430b792f302e0a..f18a9bd1b56eca8cf68b7eb32e210428da0d0d35 100644 --- a/typo3/sysext/fluid/Classes/ViewHelpers/Form/AbstractFormViewHelper.php +++ b/typo3/sysext/fluid/Classes/ViewHelpers/Form/AbstractFormViewHelper.php @@ -38,7 +38,7 @@ abstract class AbstractFormViewHelper extends \TYPO3\CMS\Fluid\Core\ViewHelper\A if (!$this->viewHelperVariableContainer->exists('TYPO3\\CMS\\Fluid\\ViewHelpers\\FormViewHelper', 'fieldNamePrefix')) { return $fieldName; } - $fieldNamePrefix = (string) $this->viewHelperVariableContainer->get('TYPO3\\CMS\\Fluid\\ViewHelpers\\FormViewHelper', 'fieldNamePrefix'); + $fieldNamePrefix = (string)$this->viewHelperVariableContainer->get('TYPO3\\CMS\\Fluid\\ViewHelpers\\FormViewHelper', 'fieldNamePrefix'); if ($fieldNamePrefix === '') { return $fieldName; } diff --git a/typo3/sysext/fluid/Classes/ViewHelpers/Form/SelectViewHelper.php b/typo3/sysext/fluid/Classes/ViewHelpers/Form/SelectViewHelper.php index 7cbd416069c70b9960031999e82d0699dca64873..dacf9043686f3254b701dbc5ea994a173c4224dd 100644 --- a/typo3/sysext/fluid/Classes/ViewHelpers/Form/SelectViewHelper.php +++ b/typo3/sysext/fluid/Classes/ViewHelpers/Form/SelectViewHelper.php @@ -160,7 +160,7 @@ class SelectViewHelper extends \TYPO3\CMS\Fluid\ViewHelpers\Form\AbstractFormFie $key = \TYPO3\CMS\Extbase\Reflection\ObjectAccess::getPropertyPath($value, $this->arguments['optionValueField']); if (is_object($key)) { if (method_exists($key, '__toString')) { - $key = (string) $key; + $key = (string)$key; } else { throw new \TYPO3\CMS\Fluid\Core\ViewHelper\Exception('Identifying value for object of class "' . get_class($value) . '" was an object.', 1247827428); } @@ -169,7 +169,7 @@ class SelectViewHelper extends \TYPO3\CMS\Fluid\ViewHelpers\Form\AbstractFormFie } elseif ($this->persistenceManager->getIdentifierByObject($value) !== NULL) { $key = $this->persistenceManager->getIdentifierByObject($value); } elseif (method_exists($value, '__toString')) { - $key = (string) $value; + $key = (string)$value; } else { throw new \TYPO3\CMS\Fluid\Core\ViewHelper\Exception('No identifying value for object of class "' . get_class($value) . '" found.', 1247826696); } @@ -177,13 +177,13 @@ class SelectViewHelper extends \TYPO3\CMS\Fluid\ViewHelpers\Form\AbstractFormFie $value = \TYPO3\CMS\Extbase\Reflection\ObjectAccess::getPropertyPath($value, $this->arguments['optionLabelField']); if (is_object($value)) { if (method_exists($value, '__toString')) { - $value = (string) $value; + $value = (string)$value; } else { throw new \TYPO3\CMS\Fluid\Core\ViewHelper\Exception('Label value for object of class "' . get_class($value) . '" was an object without a __toString() method.', 1247827553); } } } elseif (method_exists($value, '__toString')) { - $value = (string) $value; + $value = (string)$value; // TODO: use $this->persistenceManager->isNewObject() once it is implemented } elseif ($this->persistenceManager->getIdentifierByObject($value) !== NULL) { $value = $this->persistenceManager->getIdentifierByObject($value); @@ -205,7 +205,7 @@ class SelectViewHelper extends \TYPO3\CMS\Fluid\ViewHelpers\Form\AbstractFormFie */ protected function isSelected($value) { $selectedValue = $this->getSelectedValue(); - if ($value === $selectedValue || (string) $value === $selectedValue) { + if ($value === $selectedValue || (string)$value === $selectedValue) { return TRUE; } if ($this->hasArgument('multiple')) { @@ -250,7 +250,7 @@ class SelectViewHelper extends \TYPO3\CMS\Fluid\ViewHelpers\Form\AbstractFormFie if ($this->persistenceManager->getIdentifierByObject($valueElement) !== NULL) { return $this->persistenceManager->getIdentifierByObject($valueElement); } else { - return (string) $valueElement; + return (string)$valueElement; } } } else { diff --git a/typo3/sysext/fluid/Classes/ViewHelpers/FormViewHelper.php b/typo3/sysext/fluid/Classes/ViewHelpers/FormViewHelper.php index 71ecbed2df9e857771b0aa76d02709a53b6ce0b4..ad3de3d1286dcaf480e5ed469a389f91d2aa44af 100644 --- a/typo3/sysext/fluid/Classes/ViewHelpers/FormViewHelper.php +++ b/typo3/sysext/fluid/Classes/ViewHelpers/FormViewHelper.php @@ -166,7 +166,7 @@ class FormViewHelper extends \TYPO3\CMS\Fluid\ViewHelpers\Form\AbstractFormViewH $formActionUri = $this->arguments['actionUri']; } else { $uriBuilder = $this->controllerContext->getUriBuilder(); - $formActionUri = $uriBuilder->reset()->setTargetPageUid($this->arguments['pageUid'])->setTargetPageType($this->arguments['pageType'])->setNoCache($this->arguments['noCache'])->setUseCacheHash(!$this->arguments['noCacheHash'])->setSection($this->arguments['section'])->setCreateAbsoluteUri($this->arguments['absolute'])->setArguments((array) $this->arguments['additionalParams'])->setAddQueryString($this->arguments['addQueryString'])->setArgumentsToBeExcludedFromQueryString((array) $this->arguments['argumentsToBeExcludedFromQueryString'])->setFormat($this->arguments['format'])->uriFor($this->arguments['action'], $this->arguments['arguments'], $this->arguments['controller'], $this->arguments['extensionName'], $this->arguments['pluginName']); + $formActionUri = $uriBuilder->reset()->setTargetPageUid($this->arguments['pageUid'])->setTargetPageType($this->arguments['pageType'])->setNoCache($this->arguments['noCache'])->setUseCacheHash(!$this->arguments['noCacheHash'])->setSection($this->arguments['section'])->setCreateAbsoluteUri($this->arguments['absolute'])->setArguments((array)$this->arguments['additionalParams'])->setAddQueryString($this->arguments['addQueryString'])->setArgumentsToBeExcludedFromQueryString((array)$this->arguments['argumentsToBeExcludedFromQueryString'])->setFormat($this->arguments['format'])->uriFor($this->arguments['action'], $this->arguments['arguments'], $this->arguments['controller'], $this->arguments['extensionName'], $this->arguments['pluginName']); $this->formActionUriArguments = $uriBuilder->getArguments(); } $this->tag->addAttribute('action', $formActionUri); diff --git a/typo3/sysext/fluid/Classes/ViewHelpers/ImageViewHelper.php b/typo3/sysext/fluid/Classes/ViewHelpers/ImageViewHelper.php index a100e3e0bd09e2d1ffd3e2c9d078c88bdbe31225..3a29798f43837ba4a658e225461286d6de343f92 100644 --- a/typo3/sysext/fluid/Classes/ViewHelpers/ImageViewHelper.php +++ b/typo3/sysext/fluid/Classes/ViewHelpers/ImageViewHelper.php @@ -83,7 +83,7 @@ class ImageViewHelper extends \TYPO3\CMS\Fluid\Core\ViewHelper\AbstractTagBasedV * Resizes a given image (if required) and renders the respective img tag * * @see http://typo3.org/documentation/document-library/references/doc_core_tsref/4.2.0/view/1/5/#id4164427 - * @param string $src a path to a file, a combined FAL identifier or an uid (integer). If $treatIdAsReference is set, the integer is considered the uid of the sys_file_reference record. If you already got a FAL object, consider using the $image parameter instead + * @param string $src a path to a file, a combined FAL identifier or an uid (int). If $treatIdAsReference is set, the integer is considered the uid of the sys_file_reference record. If you already got a FAL object, consider using the $image parameter instead * @param string $width width of the image. This can be a numeric value representing the fixed width of the image in pixels. But you can also perform simple calculations by adding "m" or "c" to the value. See imgResource.width for possible options. * @param string $height height of the image. This can be a numeric value representing the fixed height of the image in pixels. But you can also perform simple calculations by adding "m" or "c" to the value. See imgResource.width for possible options. * @param int $minWidth minimum width of the image diff --git a/typo3/sysext/form/Classes/Domain/Factory/JsonToTypoScript.php b/typo3/sysext/form/Classes/Domain/Factory/JsonToTypoScript.php index 202fcd689959df0dfe0f68c7f86d09f3da9a28fe..35291c8ef39445bbd12be98e8aac74c12bce9083 100644 --- a/typo3/sysext/form/Classes/Domain/Factory/JsonToTypoScript.php +++ b/typo3/sysext/form/Classes/Domain/Factory/JsonToTypoScript.php @@ -55,7 +55,7 @@ class JsonToTypoScript { * @return string The typoscript for the form */ public function convert($json) { - $elements = json_decode((string) $json, TRUE); + $elements = json_decode((string)$json, TRUE); $typoscriptArray = array(); $typoscript = NULL; $this->convertToTyposcriptArray($elements, $typoscriptArray); @@ -523,7 +523,7 @@ class JsonToTypoScript { case 'content': case 'name': - $parent[$elementCounter . '.'][$key] = (string) $value; + $parent[$elementCounter . '.'][$key] = (string)$value; break; } } diff --git a/typo3/sysext/form/Classes/Domain/Factory/TypoScriptFactory.php b/typo3/sysext/form/Classes/Domain/Factory/TypoScriptFactory.php index 7b086ef25b9d235d92d48dba51b8426e20e18fea..66abf712643ae1d69127f760d4e8e4c3014584cf 100644 --- a/typo3/sysext/form/Classes/Domain/Factory/TypoScriptFactory.php +++ b/typo3/sysext/form/Classes/Domain/Factory/TypoScriptFactory.php @@ -61,7 +61,7 @@ class TypoScriptFactory implements \TYPO3\CMS\Core\SingletonInterface { * @return void */ public function setDisableContentElement($disableContentElement) { - $this->disableContentElement = (bool) $disableContentElement; + $this->disableContentElement = (bool)$disableContentElement; } /** @@ -157,7 +157,7 @@ class TypoScriptFactory implements \TYPO3\CMS\Core\SingletonInterface { * @throws \InvalidArgumentException */ public function createElement($class, array $arguments = array()) { - $class = strtolower((string) $class); + $class = strtolower((string)$class); if ($class === 'form') { $className = 'TYPO3\\CMS\\Form\\Domain\\Model\\' . ucfirst($class); } else { diff --git a/typo3/sysext/form/Classes/Domain/Model/Additional/AbstractAdditionalElement.php b/typo3/sysext/form/Classes/Domain/Model/Additional/AbstractAdditionalElement.php index 6918a4757045a17abbc14e8b0d3340a98a164c15..d637a829573108ae74dca183dfcd0eaebb01e474 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Additional/AbstractAdditionalElement.php +++ b/typo3/sysext/form/Classes/Domain/Model/Additional/AbstractAdditionalElement.php @@ -78,7 +78,7 @@ abstract class AbstractAdditionalElement { * @return void */ public function setLayout($layout) { - $this->layout = (string) $layout; + $this->layout = (string)$layout; } /** diff --git a/typo3/sysext/form/Classes/Domain/Model/Additional/AdditionalAdditionalElement.php b/typo3/sysext/form/Classes/Domain/Model/Additional/AdditionalAdditionalElement.php index cc9e73c599aa13af663e4c69ebf46f9eb26eb507..9c3f52fe6a1f6a8d1d7ccccbf4bfc883843d6c45 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Additional/AdditionalAdditionalElement.php +++ b/typo3/sysext/form/Classes/Domain/Model/Additional/AdditionalAdditionalElement.php @@ -37,7 +37,7 @@ class AdditionalAdditionalElement { * @return AdditionalAdditionalElement */ public function addAdditional($class, $type, $value) { - $class = strtolower((string) $class); + $class = strtolower((string)$class); $className = 'TYPO3\\CMS\\Form\\Domain\\Model\\Additional\\' . ucfirst($class) . 'AdditionalElement'; $this->additional[$class] = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance($className, $type, $value); return $this; diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/AcceptAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/AcceptAttribute.php index 8f839c1af062a1ee5ab2a48e2035edb64951f9e2..5e74eb47f3e6cccb82801e0f1e37530d3253aa0f 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/AcceptAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/AcceptAttribute.php @@ -37,7 +37,7 @@ class AcceptAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAtt * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/AcceptCharsetAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/AcceptCharsetAttribute.php index ba32c01cf8d74a148796c15997cad2f8cbf9e3d4..ff80795af2085dfaa6499a3dd0b0149c852409eb 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/AcceptCharsetAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/AcceptCharsetAttribute.php @@ -43,7 +43,7 @@ class AcceptCharsetAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\Abst * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/AccesskeyAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/AccesskeyAttribute.php index 742c98f054fc5269d25ffbb334bbc15ab533a2ab..9756aa7d1e4ce3e0b8bdc095f8b198092c8ca301 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/AccesskeyAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/AccesskeyAttribute.php @@ -41,7 +41,7 @@ class AccesskeyAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\Abstract * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/AltAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/AltAttribute.php index 0eb65150f8203eb1bb1a9fef1ba8e59735c13e90..22b7a3cd3caf4d8a9cd5d57972d510a2fe80cb5c 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/AltAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/AltAttribute.php @@ -33,7 +33,7 @@ class AltAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttrib * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/AttributesAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/AttributesAttribute.php index b6dd7a5f4a735a30fa50c27502c4b83a3cab3906..fd0882e7980a4d8805b35a281fe0f2e67445d6af 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/AttributesAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/AttributesAttribute.php @@ -63,7 +63,7 @@ class AttributesAttribute { * @return tx_form_Domain_Model_Attributes */ public function addAttribute($class, $value) { - $class = strtolower((string) $class); + $class = strtolower((string)$class); $className = 'TYPO3\\CMS\\Form\\Domain\\Model\\Attribute\\' . ucfirst($class) . 'Attribute'; $this->attributes[$class] = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance($className, $value, $this->elementId); return $this; diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/CheckedAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/CheckedAttribute.php index b015155c97f50059f5d19fea634d169785cf06eb..1c031420a015a2ca073e70ca649a88386ce534f1 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/CheckedAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/CheckedAttribute.php @@ -34,7 +34,7 @@ class CheckedAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAt * @return string Attribute value */ public function getValue() { - if (((int)$this->value === 1 || (bool) $this->value === TRUE) || strtolower((string) $this->value === 'checked')) { + if (((int)$this->value === 1 || (bool)$this->value === TRUE) || strtolower((string)$this->value === 'checked')) { $attribute = 'checked'; } return $attribute; diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/ClassAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/ClassAttribute.php index 8a793bc5f02a4440f5e3d4ba982071b2a9ecc1ac..0c82e7855e9983a4cf0205a5c5535d3cc5c458cf 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/ClassAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/ClassAttribute.php @@ -33,7 +33,7 @@ class ClassAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttr * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/DirAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/DirAttribute.php index 2e1d5264eeef926fc460995febd07fd5ed95356c..372d017653968944c55b63fa38c3b200901a1946 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/DirAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/DirAttribute.php @@ -42,7 +42,7 @@ class DirAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttrib * @return string Attribute value */ public function getValue() { - $value = strtolower((string) $this->value); + $value = strtolower((string)$this->value); if ($value == 'ltr' || $value == 'rtl') { $attribute = $value; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/DisabledAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/DisabledAttribute.php index 07687fba63a3e0a0906f0caad925e5ac9a0322a0..32bb4a68718a3f277d8d2c843a48c1d46e455d58 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/DisabledAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/DisabledAttribute.php @@ -43,7 +43,7 @@ class DisabledAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractA * @return string Attribute value */ public function getValue() { - if (((int)$this->value === 1 || (bool) $this->value === TRUE) || strtolower((string) $this->value) === 'disabled') { + if (((int)$this->value === 1 || (bool)$this->value === TRUE) || strtolower((string)$this->value) === 'disabled') { $attribute = 'disabled'; } return $attribute; diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/EnctypeAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/EnctypeAttribute.php index 670d5586336d341bcc3dc16f7c1d726c3a6b5660..9bcd004a5c0b80bb94701fb1277da1a30cf2146a 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/EnctypeAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/EnctypeAttribute.php @@ -35,7 +35,7 @@ class EnctypeAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAt * @return string Attribute value */ public function getValue() { - $value = strtolower((string) $this->value); + $value = strtolower((string)$this->value); if ($value == 'multipart/form-data' || $value == 'application/x-www-form-urlencoded') { $attribute = $value; } elseif (!empty($GLOBALS['TYPO3_CONF_VARS']['SYS']['form_enctype'])) { diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/IdAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/IdAttribute.php index 780888568971c290d8b883bc76169a015baa8437..b79cd9c91840a831b9f3c3d03f2bcfcef672d3f8 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/IdAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/IdAttribute.php @@ -32,7 +32,7 @@ class IdAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttribu * @return string Attribute value */ public function getValue() { - $value = (string) $this->value; + $value = (string)$this->value; if ($this->elementClassName === 'TYPO3\\CMS\\Form\\Domain\\Model\\Form') { if (empty($value)) { $value = 'form-' . $GLOBALS['TSFE']->id; diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/LabelAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/LabelAttribute.php index 01759d604edd22cea7e2ca88c8a6826d13b5ce47..9f4be2a7cd9e9c4897f6ad696cde45ac1033d266 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/LabelAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/LabelAttribute.php @@ -34,7 +34,7 @@ class LabelAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttr * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/LangAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/LangAttribute.php index af08f8f07b27ce0975a7e3828377cde05b743b1f..3c301d23595ae4ee05ec644c26981970c10de4e3 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/LangAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/LangAttribute.php @@ -44,7 +44,7 @@ class LangAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttri * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/MethodAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/MethodAttribute.php index 6f378f7e3fafbe5824a2265dd265ea71fe4ff165..21d6721df0a4a5bef5549a70a061f7acc47180f6 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/MethodAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/MethodAttribute.php @@ -33,7 +33,7 @@ class MethodAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAtt * @return string Attribute value */ public function getValue() { - $value = strtolower((string) $this->value); + $value = strtolower((string)$this->value); if ($value == 'post' || $value == 'get') { $attribute = $value; } else { diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/NameAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/NameAttribute.php index 1615b0bb7dc21ec0c3ff7b6b1d6beba6d4a306dc..346194422fd2e336a8e25d89c1f316aad63fdaa7 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/NameAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/NameAttribute.php @@ -41,7 +41,7 @@ class NameAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttri * @return string */ public function getValueWithoutPrefix() { - $value = (string) $this->value; + $value = (string)$this->value; // Change spaces into hyphens $value = preg_replace('/\\s/', '-', $value); // Remove non-word characters @@ -85,7 +85,7 @@ class NameAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttri * @return \TYPO3\CMS\Form\Domain\Model\Attribute\NameAttribute */ public function setAddition($addition) { - $this->addition = (string) $addition; + $this->addition = (string)$addition; return $this; } @@ -97,7 +97,7 @@ class NameAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttri * @return void */ public function setReturnValueWithoutPrefix($parameter) { - $this->returnValueWithoutPrefix = (bool) $parameter; + $this->returnValueWithoutPrefix = (bool)$parameter; } } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/SizeAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/SizeAttribute.php index b2763ec3e57378e4c1a02f8e25b60b64a58a5eb3..8c079275e5edff5c66b37989ab7df39bae895f04 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/SizeAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/SizeAttribute.php @@ -29,7 +29,7 @@ class SizeAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttri * This attribute tells the user agent the initial width of the control. * The width is given in pixels except when type attribute * has the value "text" or "password". - * In that case, its value refers to the (integer) number of characters. + * In that case, its value refers to the (int) number of characters. * * @return int Attribute value */ diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/StyleAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/StyleAttribute.php index 08937be5b7f9f7528fe9233b8ae0fb61aafea44b..3318d3364bef2908a1587a4515e27b4886e62223 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/StyleAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/StyleAttribute.php @@ -31,7 +31,7 @@ class StyleAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttr * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/TitleAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/TitleAttribute.php index 3e6040be6adb50f46846dbcea75e5e44b50dbc33..7e6d74d82146f51d63a51cf5e11dc936ce805eb8 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/TitleAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/TitleAttribute.php @@ -41,7 +41,7 @@ class TitleAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttr * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/TypeAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/TypeAttribute.php index 84e7d37866a8c9a2a00d79a0ed9c72ff991a0964..9f0e3c9c70865787cfc051e5ff6f969d34cbcf7a 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/TypeAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/TypeAttribute.php @@ -47,7 +47,7 @@ class TypeAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttri * @return string Attribute value */ public function getValue() { - $attribute = strtolower((string) $this->value); + $attribute = strtolower((string)$this->value); if (empty($attribute) || !in_array($attribute, $this->allowedValues)) { $attribute = 'text'; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Attribute/ValueAttribute.php b/typo3/sysext/form/Classes/Domain/Model/Attribute/ValueAttribute.php index 04e53b95e6633ff1d0587f9572314df16376b550..c357e2d8c9a8d6bfd63d285d141b2eb74702d9fb 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Attribute/ValueAttribute.php +++ b/typo3/sysext/form/Classes/Domain/Model/Attribute/ValueAttribute.php @@ -39,7 +39,7 @@ class ValueAttribute extends \TYPO3\CMS\Form\Domain\Model\Attribute\AbstractAttr * @return string Attribute value */ public function getValue() { - $attribute = (string) $this->value; + $attribute = (string)$this->value; return $attribute; } diff --git a/typo3/sysext/form/Classes/Domain/Model/Content.php b/typo3/sysext/form/Classes/Domain/Model/Content.php index df50820ddd0d5625d96463867bb5de752b9b7ba5..82b18ab7fd6178e17ac2adbaf0e4b3afe736e3e7 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Content.php +++ b/typo3/sysext/form/Classes/Domain/Model/Content.php @@ -87,7 +87,7 @@ class Content { * @return void */ public function setTyposcript(array $typoscript) { - $this->typoscript = (array) $typoscript; + $this->typoscript = (array)$typoscript; } /** diff --git a/typo3/sysext/form/Classes/Domain/Model/Element/AbstractElement.php b/typo3/sysext/form/Classes/Domain/Model/Element/AbstractElement.php index 8f4f1d225356a0c51ebe4ee65d0a59931a07cf7c..6b01cbe7b7bb898d4e9c8e2d6c9b355d2bbabb28 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Element/AbstractElement.php +++ b/typo3/sysext/form/Classes/Domain/Model/Element/AbstractElement.php @@ -362,7 +362,7 @@ abstract class AbstractElement { * @return void */ public function setLayout($layout = '') { - $this->layout = (string) $layout; + $this->layout = (string)$layout; } /** @@ -381,7 +381,7 @@ abstract class AbstractElement { * @return void */ public function setValue($value = '') { - $this->value = (string) $value; + $this->value = (string)$value; } /** @@ -400,7 +400,7 @@ abstract class AbstractElement { * @return void */ public function setData($data = '') { - $this->data = (string) $data; + $this->data = (string)$data; } /** diff --git a/typo3/sysext/form/Classes/Domain/Model/Element/ButtonElement.php b/typo3/sysext/form/Classes/Domain/Model/Element/ButtonElement.php index 2df45a3fcc8d50ce7a02a28076a137861298891e..de2196a4bdf414cfe8fb69e766fb50e2772ca3dd 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Element/ButtonElement.php +++ b/typo3/sysext/form/Classes/Domain/Model/Element/ButtonElement.php @@ -68,11 +68,11 @@ class ButtonElement extends \TYPO3\CMS\Form\Domain\Model\Element\AbstractElement $oldValue = $this->getAttributeValue('value'); if (empty($oldValue)) { if (!empty($value)) { - $newValue = (string) $value; + $newValue = (string)$value; } else { $newValue = $localizationHandler->getLocalLanguageLabel('tx_form_domain_model_element_button.value'); } - $this->value = (string) $newValue; + $this->value = (string)$newValue; $this->setAttribute('value', $newValue); } } diff --git a/typo3/sysext/form/Classes/Domain/Model/Element/CheckboxElement.php b/typo3/sysext/form/Classes/Domain/Model/Element/CheckboxElement.php index a335f2c2ea22dbdaf9d36f61c1c3eca519f2063d..7862316f6f83cc34f8b5ba852f3caca5d2565569 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Element/CheckboxElement.php +++ b/typo3/sysext/form/Classes/Domain/Model/Element/CheckboxElement.php @@ -71,7 +71,7 @@ class CheckboxElement extends \TYPO3\CMS\Form\Domain\Model\Element\AbstractEleme */ public function checkFilterAndSetIncomingDataFromRequest() { if ($this->value === '') { - $this->value = (string) $this->getElementId(); + $this->value = (string)$this->getElementId(); $this->setAttribute('value', $this->value); } if ($this->requestHandler->has($this->getName())) { diff --git a/typo3/sysext/form/Classes/Domain/Model/Element/OptionElement.php b/typo3/sysext/form/Classes/Domain/Model/Element/OptionElement.php index e5cfe747e1ad609b51cf4cd827ba0fa88304eac6..73a985f0e0202084c51595323bf8d9d6193f3f4f 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Element/OptionElement.php +++ b/typo3/sysext/form/Classes/Domain/Model/Element/OptionElement.php @@ -86,7 +86,7 @@ class OptionElement extends \TYPO3\CMS\Form\Domain\Model\Element\AbstractElement */ public function checkFilterAndSetIncomingDataFromRequest() { if ($this->value === '') { - $this->value = (string) $this->getElementId(); + $this->value = (string)$this->getElementId(); $this->setAttribute('value', $this->value); } if (!empty($this->parentName)) { diff --git a/typo3/sysext/form/Classes/Domain/Model/Element/RadioElement.php b/typo3/sysext/form/Classes/Domain/Model/Element/RadioElement.php index d3e7983fe7bb3917e95f7f8a24148586e8703b46..517500dd22f4d9b8e86654708fbca2b047a3246a 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Element/RadioElement.php +++ b/typo3/sysext/form/Classes/Domain/Model/Element/RadioElement.php @@ -72,7 +72,7 @@ class RadioElement extends \TYPO3\CMS\Form\Domain\Model\Element\AbstractElement */ public function checkFilterAndSetIncomingDataFromRequest() { if ($this->value === '') { - $this->value = (string) $this->getElementId(); + $this->value = (string)$this->getElementId(); $this->setAttribute('value', $this->value); } if ($this->requestHandler->has($this->getName())) { diff --git a/typo3/sysext/form/Classes/Domain/Model/Element/ResetElement.php b/typo3/sysext/form/Classes/Domain/Model/Element/ResetElement.php index 9d794203f57c3daf78d1baf491abe1a235cb424a..fb4fc2e2ebbb467493a66c93c241872b495b61ab 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Element/ResetElement.php +++ b/typo3/sysext/form/Classes/Domain/Model/Element/ResetElement.php @@ -68,11 +68,11 @@ class ResetElement extends \TYPO3\CMS\Form\Domain\Model\Element\AbstractElement $oldValue = $this->getAttributeValue('value'); if (empty($oldValue)) { if (!empty($value)) { - $newValue = (string) $value; + $newValue = (string)$value; } else { $newValue = $localizationHandler->getLocalLanguageLabel('tx_form_domain_model_element_reset.value'); } - $this->value = (string) $newValue; + $this->value = (string)$newValue; $this->setAttribute('value', $newValue); } } diff --git a/typo3/sysext/form/Classes/Domain/Model/Element/SubmitElement.php b/typo3/sysext/form/Classes/Domain/Model/Element/SubmitElement.php index acb083cdcc9dedf3aebd1161eac6371db0ff1d6a..728dace8623ed0c4f8647c5be61e185aa2f50030 100644 --- a/typo3/sysext/form/Classes/Domain/Model/Element/SubmitElement.php +++ b/typo3/sysext/form/Classes/Domain/Model/Element/SubmitElement.php @@ -69,11 +69,11 @@ class SubmitElement extends \TYPO3\CMS\Form\Domain\Model\Element\AbstractElement $oldValue = $this->getAttributeValue('value'); if (empty($oldValue)) { if (!empty($value)) { - $newValue = (string) $value; + $newValue = (string)$value; } else { $newValue = $localizationHandler->getLocalLanguageLabel('tx_form_domain_model_element_submit.value'); } - $this->value = (string) $newValue; + $this->value = (string)$newValue; $this->setAttribute('value', $newValue); } } diff --git a/typo3/sysext/form/Classes/Domain/Repository/ContentRepository.php b/typo3/sysext/form/Classes/Domain/Repository/ContentRepository.php index 0f63340a3f3112d7921988b09901fb46a55ecb70..61d892dbedab60e51ae488fc3f10b8ab0163bab0 100644 --- a/typo3/sysext/form/Classes/Domain/Repository/ContentRepository.php +++ b/typo3/sysext/form/Classes/Domain/Repository/ContentRepository.php @@ -31,7 +31,7 @@ class ContentRepository { public function getRecord() { $record = FALSE; $getPostVariables = \TYPO3\CMS\Core\Utility\GeneralUtility::_GP('P'); - $table = (string) $getPostVariables['table']; + $table = (string)$getPostVariables['table']; $recordId = (int)$getPostVariables['uid']; $row = \TYPO3\CMS\Backend\Utility\BackendUtility::getRecord($table, $recordId); if (is_array($row)) { diff --git a/typo3/sysext/form/Classes/Filter/AlphabeticFilter.php b/typo3/sysext/form/Classes/Filter/AlphabeticFilter.php index 94ffe7e5e6dddc7fb2b5564df691cac93e437f69..5b59222cc24860e28d087a2262ce162f233caa63 100644 --- a/typo3/sysext/form/Classes/Filter/AlphabeticFilter.php +++ b/typo3/sysext/form/Classes/Filter/AlphabeticFilter.php @@ -44,7 +44,7 @@ class AlphabeticFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { * @return void */ public function setAllowWhiteSpace($allowWhiteSpace = TRUE) { - $this->allowWhiteSpace = (bool) $allowWhiteSpace; + $this->allowWhiteSpace = (bool)$allowWhiteSpace; } /** @@ -58,7 +58,7 @@ class AlphabeticFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { public function filter($value) { $whiteSpace = $this->allowWhiteSpace ? '\\s' : ''; $pattern = '/[^\pL' . $whiteSpace . ']/u'; - return preg_replace($pattern, '', (string) $value); + return preg_replace($pattern, '', (string)$value); } } diff --git a/typo3/sysext/form/Classes/Filter/AlphanumericFilter.php b/typo3/sysext/form/Classes/Filter/AlphanumericFilter.php index 0d872ed35bf961de9bbb836c9c2333f2c831aa94..c07d5bc892fe21b2cc287a64576106ef4b911930 100644 --- a/typo3/sysext/form/Classes/Filter/AlphanumericFilter.php +++ b/typo3/sysext/form/Classes/Filter/AlphanumericFilter.php @@ -44,7 +44,7 @@ class AlphanumericFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { * @return void */ public function setAllowWhiteSpace($allowWhiteSpace = TRUE) { - $this->allowWhiteSpace = (bool) $allowWhiteSpace; + $this->allowWhiteSpace = (bool)$allowWhiteSpace; } /** @@ -58,7 +58,7 @@ class AlphanumericFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { public function filter($value) { $whiteSpace = $this->allowWhiteSpace ? '\\s' : ''; $pattern = '/[^\pL\d' . $whiteSpace . ']/u'; - return preg_replace($pattern, '', (string) $value); + return preg_replace($pattern, '', (string)$value); } } diff --git a/typo3/sysext/form/Classes/Filter/CurrencyFilter.php b/typo3/sysext/form/Classes/Filter/CurrencyFilter.php index 98583187b1800872f1cc7482fb1fecf2e79b4513..7c9cd76b0df2480c391011f40ed5e9a28a0c65a4 100644 --- a/typo3/sysext/form/Classes/Filter/CurrencyFilter.php +++ b/typo3/sysext/form/Classes/Filter/CurrencyFilter.php @@ -57,7 +57,7 @@ class CurrencyFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { if (empty($decimalsPoint)) { $this->decimalsPoint = '.'; } else { - $this->decimalsPoint = (string) $decimalsPoint; + $this->decimalsPoint = (string)$decimalsPoint; } return $this; } @@ -76,7 +76,7 @@ class CurrencyFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { } elseif ($thousandSeparator === 'none') { $this->thousandSeparator = ''; } else { - $this->thousandSeparator = (string) $thousandSeparator; + $this->thousandSeparator = (string)$thousandSeparator; } return $this; } @@ -89,7 +89,7 @@ class CurrencyFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { * @return string */ public function filter($value) { - $value = (double) ((string) $value); + $value = (double) ((string)$value); return number_format($value, 2, $this->decimalsPoint, $this->thousandSeparator); } diff --git a/typo3/sysext/form/Classes/Filter/DigitFilter.php b/typo3/sysext/form/Classes/Filter/DigitFilter.php index 7aa09cc50a3de4c16de4220865fca6b0b69567f1..f141bee5a032f799f2c34caeb9f88935c44f4336 100644 --- a/typo3/sysext/form/Classes/Filter/DigitFilter.php +++ b/typo3/sysext/form/Classes/Filter/DigitFilter.php @@ -30,7 +30,7 @@ class DigitFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { */ public function filter($value) { $pattern = '/[^0-9]/'; - return preg_replace($pattern, '', (string) $value); + return preg_replace($pattern, '', (string)$value); } } diff --git a/typo3/sysext/form/Classes/Filter/RegExpFilter.php b/typo3/sysext/form/Classes/Filter/RegExpFilter.php index f518be4ea56c1d2bc8cb970ba63d5b43428bb910..08bd90959bdd705c33af0de5abe32c74a6196238 100644 --- a/typo3/sysext/form/Classes/Filter/RegExpFilter.php +++ b/typo3/sysext/form/Classes/Filter/RegExpFilter.php @@ -44,7 +44,7 @@ class RegExpFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { * @return void */ public function setRegularExpression($expression) { - $this->regularExpression = (string) $expression; + $this->regularExpression = (string)$expression; } /** @@ -55,7 +55,7 @@ class RegExpFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { * @return string */ public function filter($value) { - return preg_replace($this->regularExpression, '', (string) $value); + return preg_replace($this->regularExpression, '', (string)$value); } } diff --git a/typo3/sysext/form/Classes/Filter/StripNewLinesFilter.php b/typo3/sysext/form/Classes/Filter/StripNewLinesFilter.php index b5ed77e895dcfab284f0670c903d6fb1d93024c2..8473c0770a09b287a017224f5421eb45e930c7cc 100644 --- a/typo3/sysext/form/Classes/Filter/StripNewLinesFilter.php +++ b/typo3/sysext/form/Classes/Filter/StripNewLinesFilter.php @@ -28,7 +28,7 @@ class StripNewLinesFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { * @return string */ public function filter($value) { - return str_replace(array(LF, CR), ' ', (string) $value); + return str_replace(array(LF, CR), ' ', (string)$value); } } diff --git a/typo3/sysext/form/Classes/Filter/TrimFilter.php b/typo3/sysext/form/Classes/Filter/TrimFilter.php index c8331ee3265c2995d058f5a81766d629967d562a..725138f62f8fcef0348c10f0083842b006bc0851 100644 --- a/typo3/sysext/form/Classes/Filter/TrimFilter.php +++ b/typo3/sysext/form/Classes/Filter/TrimFilter.php @@ -59,9 +59,9 @@ class TrimFilter implements \TYPO3\CMS\Form\Filter\FilterInterface { */ public function filter($value) { if ($this->characterList === NULL) { - return trim((string) $value); + return trim((string)$value); } else { - return trim((string) $value, $this->characterList); + return trim((string)$value, $this->characterList); } } diff --git a/typo3/sysext/form/Classes/Layout.php b/typo3/sysext/form/Classes/Layout.php index 324971c444f56d3c71c7123d7fe0fa9cfaf2f881..9a99ceb6fc4b92ae73f94995b9c7fc3886ae3fd6 100644 --- a/typo3/sysext/form/Classes/Layout.php +++ b/typo3/sysext/form/Classes/Layout.php @@ -81,7 +81,7 @@ class Layout implements \TYPO3\CMS\Core\SingletonInterface { * @return \TYPO3\CMS\Form\Layout */ public function setLayoutByElement($elementName, $layout) { - $this->layout[$elementName] = (string) $layout; + $this->layout[$elementName] = (string)$layout; return $this; } diff --git a/typo3/sysext/form/Classes/Localization.php b/typo3/sysext/form/Classes/Localization.php index 27d09c782dfab4a74a571041f86fef94c68d1239..6514a574dbe4e4659d65866f58f56ee783314df2 100644 --- a/typo3/sysext/form/Classes/Localization.php +++ b/typo3/sysext/form/Classes/Localization.php @@ -34,7 +34,7 @@ class Localization { * @param string $localLanguageFile File reference to the local language file */ public function __construct($localLanguageFile = 'LLL:EXT:form/Resources/Private/Language/locallang_controller.xlf') { - $this->localLanguageFile = (string) $localLanguageFile; + $this->localLanguageFile = (string)$localLanguageFile; } /** diff --git a/typo3/sysext/form/Classes/Request.php b/typo3/sysext/form/Classes/Request.php index 9d0bc6085db4a3f0908f557eee562b93d7b245bf..4fa7063eb2c00671dfafcf1888ef8e722cc51ca5 100644 --- a/typo3/sysext/form/Classes/Request.php +++ b/typo3/sysext/form/Classes/Request.php @@ -58,7 +58,7 @@ class Request implements \TYPO3\CMS\Core\SingletonInterface { if (empty($prefix)) { $prefix = 'tx_form'; } - $prefix = preg_replace('/\\s/', '_', (string) $prefix); + $prefix = preg_replace('/\\s/', '_', (string)$prefix); $this->prefix = preg_replace('/[^a-zA-Z0-9_\\-]/', '', $prefix); } @@ -84,7 +84,7 @@ class Request implements \TYPO3\CMS\Core\SingletonInterface { 'get', 'session' ); - $method = strtolower((string) $method); + $method = strtolower((string)$method); if ($GLOBALS['TSFE']->loginUser) { $this->sessionData = $GLOBALS['TSFE']->fe_user->getKey('user', $this->prefix); } else { diff --git a/typo3/sysext/form/Classes/Utility/FilterUtility.php b/typo3/sysext/form/Classes/Utility/FilterUtility.php index b0973a2629369171dbd1c1a2ab6b566081534e47..3bd78bcbaaa51eb6399f39875dc48e4cfe19e4ca 100644 --- a/typo3/sysext/form/Classes/Utility/FilterUtility.php +++ b/typo3/sysext/form/Classes/Utility/FilterUtility.php @@ -99,7 +99,7 @@ class FilterUtility implements \TYPO3\CMS\Form\Filter\FilterInterface { * @return \TYPO3\CMS\Form\Filter\FilterInterface The filter object */ static public function createFilter($class, array $arguments = NULL) { - $class = strtolower((string) $class); + $class = strtolower((string)$class); $className = 'TYPO3\\CMS\\Form\\Filter\\' . ucfirst($class) . 'Filter'; if (is_null($arguments)) { $filter = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance($className); diff --git a/typo3/sysext/form/Classes/Utility/TypoScriptToJsonConverter.php b/typo3/sysext/form/Classes/Utility/TypoScriptToJsonConverter.php index 015247386999daca5c88706c52af76e780288721..998855fbbba680858c8f017539a8cd4b640592eb 100644 --- a/typo3/sysext/form/Classes/Utility/TypoScriptToJsonConverter.php +++ b/typo3/sysext/form/Classes/Utility/TypoScriptToJsonConverter.php @@ -49,7 +49,7 @@ class TypoScriptToJsonConverter { * @return \TYPO3\CMS\Form\Domain\Model\Json\AbstractJsonElement */ public function createElement($class, array $arguments = array()) { - $class = strtolower((string) $class); + $class = strtolower((string)$class); $className = 'TYPO3\\CMS\\Form\\Domain\\Model\Json\\' . ucfirst($class) . 'JsonElement'; $this->addValidationRules($arguments); /** @var $object \TYPO3\CMS\Form\Domain\Model\Json\AbstractJsonElement */ diff --git a/typo3/sysext/form/Classes/Utility/ValidatorUtility.php b/typo3/sysext/form/Classes/Utility/ValidatorUtility.php index 26e9d9f50fb9e477aa0af5164b2c0b18cc4c4434..2ba4161789badab6cd5cad01dff6bb18d605b39b 100644 --- a/typo3/sysext/form/Classes/Utility/ValidatorUtility.php +++ b/typo3/sysext/form/Classes/Utility/ValidatorUtility.php @@ -66,7 +66,7 @@ class ValidatorUtility implements \TYPO3\CMS\Core\SingletonInterface { * @return \TYPO3\CMS\Form\Validation\AbstractValidator The rule object */ public function createRule($class, $arguments = array()) { - $class = strtolower((string) $class); + $class = strtolower((string)$class); $className = 'TYPO3\\CMS\\Form\\Validation\\' . ucfirst($class) . 'Validator'; $rule = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance($className, $arguments); return $rule; @@ -85,8 +85,8 @@ class ValidatorUtility implements \TYPO3\CMS\Core\SingletonInterface { $prefix = $this->getPrefix(); $this->rules[$prefix][] = array( 'instance' => (object) $rule, - 'fieldName' => (string) $fieldName, - 'breakOnError' => (bool) $breakOnError + 'fieldName' => (string)$fieldName, + 'breakOnError' => (bool)$breakOnError ); if ($rule->messageMustBeDisplayed()) { if (!isset($this->messages[$prefix][$fieldName])) { diff --git a/typo3/sysext/form/Classes/Validation/AbstractValidator.php b/typo3/sysext/form/Classes/Validation/AbstractValidator.php index b73893399a08e2bfb3630ec7d0aeb564280328cf..00ff0e160f688e1f204bd67ad5c1380e27cc77c1 100644 --- a/typo3/sysext/form/Classes/Validation/AbstractValidator.php +++ b/typo3/sysext/form/Classes/Validation/AbstractValidator.php @@ -108,7 +108,7 @@ abstract class AbstractValidator implements \TYPO3\CMS\Form\Validation\Validator * @return object The rule object */ public function setFieldName($fieldName) { - $this->fieldName = (string) $fieldName; + $this->fieldName = (string)$fieldName; return $this; } @@ -168,7 +168,7 @@ abstract class AbstractValidator implements \TYPO3\CMS\Form\Validation\Validator } else { $value = $message; } - $this->message['cObj'] = (string) $type; + $this->message['cObj'] = (string)$type; $this->message['cObj.'] = $value; } @@ -200,7 +200,7 @@ abstract class AbstractValidator implements \TYPO3\CMS\Form\Validation\Validator } else { $value = $error; } - $this->error['cObj'] = (string) $type; + $this->error['cObj'] = (string)$type; $this->error['cObj.'] = $value; } @@ -214,7 +214,7 @@ abstract class AbstractValidator implements \TYPO3\CMS\Form\Validation\Validator if ($show === NULL) { $this->showMessage = TRUE; } else { - $this->showMessage = (bool) $show; + $this->showMessage = (bool)$show; } return $this; } diff --git a/typo3/sysext/form/Classes/Validation/AlphabeticValidator.php b/typo3/sysext/form/Classes/Validation/AlphabeticValidator.php index bee55b2e5fcc6da1709a6d9fbe9f084606c9a67f..208ccd3e35a0c1c32667a85fc6695673ae791161 100644 --- a/typo3/sysext/form/Classes/Validation/AlphabeticValidator.php +++ b/typo3/sysext/form/Classes/Validation/AlphabeticValidator.php @@ -76,7 +76,7 @@ class AlphabeticValidator extends \TYPO3\CMS\Form\Validation\AbstractValidator { if ($allowWhiteSpace === NULL) { $this->allowWhiteSpace = FALSE; } else { - $this->allowWhiteSpace = (bool) $allowWhiteSpace; + $this->allowWhiteSpace = (bool)$allowWhiteSpace; } return $this; } diff --git a/typo3/sysext/form/Classes/Validation/AlphanumericValidator.php b/typo3/sysext/form/Classes/Validation/AlphanumericValidator.php index 3a15f5499ae202c46118ce57e2aba8f9f95aeb7b..a8175cdb80eec51876ee2dccd350d47cf96ec5ab 100644 --- a/typo3/sysext/form/Classes/Validation/AlphanumericValidator.php +++ b/typo3/sysext/form/Classes/Validation/AlphanumericValidator.php @@ -69,7 +69,7 @@ class AlphanumericValidator extends \TYPO3\CMS\Form\Validation\AbstractValidator if ($allowWhiteSpace === NULL) { $this->allowWhiteSpace = FALSE; } else { - $this->allowWhiteSpace = (bool) $allowWhiteSpace; + $this->allowWhiteSpace = (bool)$allowWhiteSpace; } return $this; } diff --git a/typo3/sysext/form/Classes/Validation/BetweenValidator.php b/typo3/sysext/form/Classes/Validation/BetweenValidator.php index 1ffa17fbc1a6d09491e759f005414d5571b68847..80015f5770a3d1d0408e2884dfc2f390909167e8 100644 --- a/typo3/sysext/form/Classes/Validation/BetweenValidator.php +++ b/typo3/sysext/form/Classes/Validation/BetweenValidator.php @@ -107,7 +107,7 @@ class BetweenValidator extends \TYPO3\CMS\Form\Validation\AbstractValidator impl if ($inclusive === NULL) { $this->inclusive = FALSE; } else { - $this->inclusive = (bool) $inclusive; + $this->inclusive = (bool)$inclusive; } return $this; } diff --git a/typo3/sysext/form/Classes/Validation/DateValidator.php b/typo3/sysext/form/Classes/Validation/DateValidator.php index 6cdbe41d818840a38cf9383994d58d892aee4d4a..491e17edec7333e406ffb1f7f1b55e2dba0080cb 100644 --- a/typo3/sysext/form/Classes/Validation/DateValidator.php +++ b/typo3/sysext/form/Classes/Validation/DateValidator.php @@ -66,7 +66,7 @@ class DateValidator extends \TYPO3\CMS\Form\Validation\AbstractValidator { if ($format === NULL) { $this->format = '%e-%m-%Y'; } else { - $this->format = (string) $format; + $this->format = (string)$format; } return $this; } diff --git a/typo3/sysext/form/Classes/Validation/EqualsValidator.php b/typo3/sysext/form/Classes/Validation/EqualsValidator.php index 4cc67a3a8f8667b0070fbbdcc8e92ab9d4377a87..e4a706da5dae096e215158e7f0c090e5dd37efa2 100644 --- a/typo3/sysext/form/Classes/Validation/EqualsValidator.php +++ b/typo3/sysext/form/Classes/Validation/EqualsValidator.php @@ -66,7 +66,7 @@ class EqualsValidator extends \TYPO3\CMS\Form\Validation\AbstractValidator { * @return Rule object */ public function setField($field) { - $this->field = (string) $field; + $this->field = (string)$field; return $this; } diff --git a/typo3/sysext/form/Classes/Validation/InArrayValidator.php b/typo3/sysext/form/Classes/Validation/InArrayValidator.php index 8a10b938e56fa90513a745df0b9856c4224a97ef..e1097aabccaee04b0ce85d7c9f95c73bbaafae3e 100644 --- a/typo3/sysext/form/Classes/Validation/InArrayValidator.php +++ b/typo3/sysext/form/Classes/Validation/InArrayValidator.php @@ -68,7 +68,7 @@ class InArrayValidator extends \TYPO3\CMS\Form\Validation\AbstractValidator { * @return object Rule object */ public function setArray($array) { - $this->array = (array) $array; + $this->array = (array)$array; return $this; } @@ -79,7 +79,7 @@ class InArrayValidator extends \TYPO3\CMS\Form\Validation\AbstractValidator { * @return object Rule object */ public function setStrict($strict) { - $this->strict = (bool) $strict; + $this->strict = (bool)$strict; return $this; } diff --git a/typo3/sysext/form/Classes/Validation/RegExpValidator.php b/typo3/sysext/form/Classes/Validation/RegExpValidator.php index 4fb35e7f25cd78209878261527e4dd3950a8241d..0f05d231d5c4223cad8bebee4fc24d91260250c8 100644 --- a/typo3/sysext/form/Classes/Validation/RegExpValidator.php +++ b/typo3/sysext/form/Classes/Validation/RegExpValidator.php @@ -61,7 +61,7 @@ class RegExpValidator extends \TYPO3\CMS\Form\Validation\AbstractValidator { * @return object Rule object */ public function setRegularExpression($expression) { - $this->regularExpression = (string) $expression; + $this->regularExpression = (string)$expression; return $this; } diff --git a/typo3/sysext/form/Classes/View/Confirmation/Element/AbstractElementView.php b/typo3/sysext/form/Classes/View/Confirmation/Element/AbstractElementView.php index 5aeab36f351874f2efdc15b1a1a4cc428d0796b1..891eb0919c02c3cc062e3e6d8068c0f0bb6eef46 100644 --- a/typo3/sysext/form/Classes/View/Confirmation/Element/AbstractElementView.php +++ b/typo3/sysext/form/Classes/View/Confirmation/Element/AbstractElementView.php @@ -167,7 +167,7 @@ abstract class AbstractElementView { * @return mixed \DOMDocument|\DOMNode XML part of the view object */ public function render($type = 'element', $returnFirstChild = TRUE) { - $useLayout = $this->getLayout((string) $type); + $useLayout = $this->getLayout((string)$type); $dom = new \DOMDocument('1.0', 'utf-8'); $dom->formatOutput = TRUE; $dom->preserveWhiteSpace = FALSE; @@ -251,7 +251,7 @@ abstract class AbstractElementView { * @return void */ public function setAttribute(\DOMElement $domElement, $key) { - $attribute = $this->model->getAttributeValue((string) $key); + $attribute = $this->model->getAttributeValue((string)$key); if (!empty($attribute)) { $domElement->setAttribute($key, $attribute); } @@ -267,7 +267,7 @@ abstract class AbstractElementView { * @return unknown_type */ public function setAttributeWithValueofOtherAttribute(\DOMElement $domElement, $key, $other) { - $attribute = $this->model->getAttributeValue((string) $other); + $attribute = $this->model->getAttributeValue((string)$other); if (!empty($attribute)) { $domElement->setAttribute($key, $attribute); } @@ -280,7 +280,7 @@ abstract class AbstractElementView { * @return object */ protected function createAdditional($class) { - $class = strtolower((string) $class); + $class = strtolower((string)$class); $className = 'TYPO3\\CMS\\Form\\View\\Confirmation\\Additional\\' . ucfirst($class) . 'AdditionalElementView'; return \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance($className, $this->model); } diff --git a/typo3/sysext/form/Classes/View/Form/Element/AbstractElementView.php b/typo3/sysext/form/Classes/View/Form/Element/AbstractElementView.php index 1f78332abd429a9b1e9bbc75ed12ddecbcd2e209..057251c3f599f3c59da8dab7b39e7d5feb50ec38 100644 --- a/typo3/sysext/form/Classes/View/Form/Element/AbstractElementView.php +++ b/typo3/sysext/form/Classes/View/Form/Element/AbstractElementView.php @@ -213,7 +213,7 @@ abstract class AbstractElementView { * @return mixed \DOMDocument|\DOMNode XML part of the view object */ public function render($type = 'element', $returnFirstChild = TRUE) { - $useLayout = $this->getLayout((string) $type); + $useLayout = $this->getLayout((string)$type); $dom = new \DOMDocument('1.0', 'utf-8'); $dom->formatOutput = TRUE; $dom->preserveWhiteSpace = FALSE; @@ -303,7 +303,7 @@ abstract class AbstractElementView { * @return void */ public function setAttribute(\DOMElement $domElement, $key) { - $value = htmlspecialchars($this->model->getAttributeValue((string) $key), ENT_QUOTES); + $value = htmlspecialchars($this->model->getAttributeValue((string)$key), ENT_QUOTES); if (!empty($value)) { $domElement->setAttribute($key, $value); } @@ -319,7 +319,7 @@ abstract class AbstractElementView { * @return unknown_type */ public function setAttributeWithValueofOtherAttribute(\DOMElement $domElement, $key, $other) { - $value = htmlspecialchars($this->model->getAttributeValue((string) $other), ENT_QUOTES); + $value = htmlspecialchars($this->model->getAttributeValue((string)$other), ENT_QUOTES); if (!empty($value)) { $domElement->setAttribute($key, $value); } @@ -332,7 +332,7 @@ abstract class AbstractElementView { * @return object */ protected function createAdditional($class) { - $class = strtolower((string) $class); + $class = strtolower((string)$class); $className = 'TYPO3\\CMS\\Form\\View\\Form\\Additional\\' . ucfirst($class) . 'AdditionalElementView'; return \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance($className, $this->model); } diff --git a/typo3/sysext/form/Classes/View/Mail/Html/Element/AbstractElementView.php b/typo3/sysext/form/Classes/View/Mail/Html/Element/AbstractElementView.php index 6f72d3c9caa4e8525e76351fb6d668aaceff4974..ea03c0ddfbe05588884d4104243be4c72a70e66c 100644 --- a/typo3/sysext/form/Classes/View/Mail/Html/Element/AbstractElementView.php +++ b/typo3/sysext/form/Classes/View/Mail/Html/Element/AbstractElementView.php @@ -164,7 +164,7 @@ abstract class AbstractElementView { * @return \DOMDocument|\DOMNode XML part of the view object */ public function render($type = 'element', $returnFirstChild = TRUE) { - $useLayout = $this->getLayout((string) $type); + $useLayout = $this->getLayout((string)$type); $dom = new \DOMDocument('1.0', 'utf-8'); $dom->formatOutput = TRUE; $dom->preserveWhiteSpace = FALSE; @@ -249,7 +249,7 @@ abstract class AbstractElementView { * @return void */ public function setAttribute(\DOMElement $domElement, $key) { - $value = htmlspecialchars($this->model->getAttributeValue((string) $key), ENT_QUOTES); + $value = htmlspecialchars($this->model->getAttributeValue((string)$key), ENT_QUOTES); if (!empty($value)) { $domElement->setAttribute($key, $value); } @@ -265,7 +265,7 @@ abstract class AbstractElementView { * @return void */ public function setAttributeWithValueofOtherAttribute(\DOMElement $domElement, $key, $other) { - $value = htmlspecialchars($this->model->getAttributeValue((string) $other), ENT_QUOTES); + $value = htmlspecialchars($this->model->getAttributeValue((string)$other), ENT_QUOTES); if (!empty($value)) { $domElement->setAttribute($key, $value); } @@ -278,7 +278,7 @@ abstract class AbstractElementView { * @return object */ protected function createAdditional($class) { - $class = strtolower((string) $class); + $class = strtolower((string)$class); $className = 'TYPO3\\CMS\\Form\\View\\Mail\\Html\\Additional\\' . ucfirst($class) . 'AdditionalElementView'; return \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance($className, $this->model); } diff --git a/typo3/sysext/frontend/Classes/Configuration/TypoScript/ConditionMatching/ConditionMatcher.php b/typo3/sysext/frontend/Classes/Configuration/TypoScript/ConditionMatching/ConditionMatcher.php index 9cc5bd81100c6eafe932a3edaee2492011809aa8..146af2be754bdfc195ac6924829d29d80708ea3a 100644 --- a/typo3/sysext/frontend/Classes/Configuration/TypoScript/ConditionMatching/ConditionMatcher.php +++ b/typo3/sysext/frontend/Classes/Configuration/TypoScript/ConditionMatching/ConditionMatcher.php @@ -114,7 +114,7 @@ class ConditionMatcher extends \TYPO3\CMS\Core\Configuration\TypoScript\Conditio $splitAgain = explode('|', $vars[1], 2); $k = trim($splitAgain[0]); if ($k) { - switch ((string) trim($vars[0])) { + switch ((string)trim($vars[0])) { case 'TSFE': $val = $this->getGlobal('TSFE|' . $vars[1]); break; @@ -158,7 +158,7 @@ class ConditionMatcher extends \TYPO3\CMS\Core\Configuration\TypoScript\Conditio * @return array The rootline for the current page. */ protected function determineRootline() { - $rootline = (array) $GLOBALS['TSFE']->tmpl->rootLine; + $rootline = (array)$GLOBALS['TSFE']->tmpl->rootLine; return $rootline; } diff --git a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php index eb56a2e5346720742794c3b428d3b4a0226d9dcc..86cfdd606a14781bc6cf62337590293408dd8b5d 100644 --- a/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php +++ b/typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php @@ -704,7 +704,7 @@ class ContentObjectRenderer { throw new \UnexpectedValueException('$hookObject must implement interface TYPO3\\CMS\\Frontend\\ContentObject\\ContentObjectGetSingleHookInterface', 1195043731); } /** @var $hookObject \TYPO3\CMS\Frontend\ContentObject\ContentObjectGetSingleHookInterface */ - $content .= $hookObject->getSingleContentObject($name, (array) $conf, $TSkey, $this); + $content .= $hookObject->getSingleContentObject($name, (array)$conf, $TSkey, $this); } } else { // Log error in AdminPanel @@ -1443,7 +1443,7 @@ class ContentObjectRenderer { 1380007853 ); } - $oneSourceCollection = $hookObject->getOneSourceCollection((array) $sourceRenderConfiguration, (array) $sourceConfiguration, $oneSourceCollection, $this); + $oneSourceCollection = $hookObject->getOneSourceCollection((array)$sourceRenderConfiguration, (array)$sourceConfiguration, $oneSourceCollection, $this); } } @@ -2512,7 +2512,7 @@ class ContentObjectRenderer { * @return string The processed input value */ public function stdWrap_required($content = '', $conf = array()) { - if ((string) $content === '') { + if ((string)$content === '') { $content = ''; $this->stopRendering[$this->stdWrapRecursionLevel] = TRUE; } @@ -4388,7 +4388,7 @@ class ContentObjectRenderer { foreach ($parts as $part) { $theVal = $part[1]; $sign = $part[0]; - if ((string) (int)$theVal === (string) $theVal) { + if ((string)(int)$theVal === (string)$theVal) { $theVal = (int)$theVal; } else { $theVal = 0; @@ -5012,11 +5012,11 @@ class ContentObjectRenderer { if (is_array($conf['addAttributes.'][$uTagName . '.'])) { foreach ($conf['addAttributes.'][$uTagName . '.'] as $kk => $vv) { if (!is_array($vv)) { - if ((string) $conf['addAttributes.'][($uTagName . '.')][($kk . '.')]['setOnly'] == 'blank') { + if ((string)$conf['addAttributes.'][($uTagName . '.')][($kk . '.')]['setOnly'] == 'blank') { if ((string)$attrib[$kk] === '') { $attrib[$kk] = $vv; } - } elseif ((string) $conf['addAttributes.'][($uTagName . '.')][($kk . '.')]['setOnly'] == 'exists') { + } elseif ((string)$conf['addAttributes.'][($uTagName . '.')][($kk . '.')]['setOnly'] == 'exists') { if (!isset($attrib[$kk])) { $attrib[$kk] = $vv; } @@ -5193,7 +5193,7 @@ class ContentObjectRenderer { */ public function getImgResource($file, $fileArray) { if (!is_array($fileArray)) { - $fileArray = (array) $fileArray; + $fileArray = (array)$fileArray; } $imageResource = NULL; if ($file === 'GIFBUILDER') { @@ -5320,7 +5320,7 @@ class ContentObjectRenderer { if (isset($imageResource)) { /** @var \TYPO3\CMS\Frontend\ContentObject\ContentObjectGetImageResourceHookInterface $hookObject */ foreach ($this->getGetImgResourceHookObjects() as $hookObject) { - $imageResource = $hookObject->getImgResourcePostProcess($file, (array) $fileArray, $imageResource, $this); + $imageResource = $hookObject->getImgResourcePostProcess($file, (array)$fileArray, $imageResource, $this); } } return $imageResource; @@ -6513,7 +6513,7 @@ class ContentObjectRenderer { * @return string The URL query part (starting with a &) */ public function getQueryArguments($conf, $overruleQueryArguments = array(), $forceOverruleArguments = FALSE) { - switch ((string) $conf['method']) { + switch ((string)$conf['method']) { case 'GET': $currentQueryArray = GeneralUtility::_GET(); break; @@ -7244,7 +7244,7 @@ class ContentObjectRenderer { $ok = 0; // Points to the field that allows further editing from frontend if not set. If set the record is locked. if (!$GLOBALS['TCA'][$table]['ctrl']['fe_admin_lock'] || !$row[$GLOBALS['TCA'][$table]['ctrl']['fe_admin_lock']]) { - // Points to the field (integer) that holds the fe_users-id of the creator fe_user + // Points to the field (int) that holds the fe_users-id of the creator fe_user if ($GLOBALS['TCA'][$table]['ctrl']['fe_cruser_id']) { $rowFEUser = (int)$row[$GLOBALS['TCA'][$table]['ctrl']['fe_cruser_id']]; if ($rowFEUser && $rowFEUser == $feUserRow['uid']) { @@ -7255,7 +7255,7 @@ class ContentObjectRenderer { if ($feEditSelf && $table == 'fe_users' && (int)$feUserRow['uid'] === (int)$row['uid']) { $ok = 1; } - // Points to the field (integer) that holds the fe_group-id of the creator fe_user's first group + // Points to the field (int) that holds the fe_group-id of the creator fe_user's first group if ($GLOBALS['TCA'][$table]['ctrl']['fe_crgroup_id']) { $rowFEUser = (int)$row[$GLOBALS['TCA'][$table]['ctrl']['fe_crgroup_id']]; if ($rowFEUser) { @@ -7284,11 +7284,11 @@ class ContentObjectRenderer { // Returns where-definition that selects user-editable records. $groupList = $allowedGroups ? implode(',', array_intersect(GeneralUtility::trimExplode(',', $feUserRow['usergroup'], TRUE), GeneralUtility::trimExplode(',', $allowedGroups, TRUE))) : $feUserRow['usergroup']; $OR_arr = array(); - // Points to the field (integer) that holds the fe_users-id of the creator fe_user + // Points to the field (int) that holds the fe_users-id of the creator fe_user if ($GLOBALS['TCA'][$table]['ctrl']['fe_cruser_id']) { $OR_arr[] = $GLOBALS['TCA'][$table]['ctrl']['fe_cruser_id'] . '=' . $feUserRow['uid']; } - // Points to the field (integer) that holds the fe_group-id of the creator fe_user's first group + // Points to the field (int) that holds the fe_group-id of the creator fe_user's first group if ($GLOBALS['TCA'][$table]['ctrl']['fe_crgroup_id']) { $values = GeneralUtility::intExplode(',', $groupList); foreach ($values as $theGroupUid) { @@ -7951,7 +7951,7 @@ class ContentObjectRenderer { $uid = (int)$uid; if (!isset($this->checkPid_cache[$uid])) { $count = $GLOBALS['TYPO3_DB']->exec_SELECTcountRows('uid', 'pages', 'uid=' . $uid . $this->enableFields('pages') . ' AND doktype NOT IN (' . $this->checkPid_badDoktypeList . ')'); - $this->checkPid_cache[$uid] = (bool) $count; + $this->checkPid_cache[$uid] = (bool)$count; } return $this->checkPid_cache[$uid]; } diff --git a/typo3/sysext/frontend/Classes/ContentObject/FlowPlayerContentObject.php b/typo3/sysext/frontend/Classes/ContentObject/FlowPlayerContentObject.php index 8782c19285a0685e83b22da16b0f3f20149b1e17..8725f7609839daedfb91eff5815d3f7dd0ca4e8f 100644 --- a/typo3/sysext/frontend/Classes/ContentObject/FlowPlayerContentObject.php +++ b/typo3/sysext/frontend/Classes/ContentObject/FlowPlayerContentObject.php @@ -291,9 +291,9 @@ class FlowPlayerContentObject extends \TYPO3\CMS\Frontend\ContentObject\Abstract $conf['filename'] = $conf['flashvars.']['url']; $conf['prefix'] = $prefix; // merge with default parameters - $conf['flashvars.'] = array_merge((array) $typeConf['default.']['flashvars.'], (array) $conf['flashvars.']); - $conf['params.'] = array_merge((array) $typeConf['default.']['params.'], (array) $conf['params.']); - $conf['attributes.'] = array_merge((array) $typeConf['default.']['attributes.'], (array) $conf['attributes.']); + $conf['flashvars.'] = array_merge((array)$typeConf['default.']['flashvars.'], (array)$conf['flashvars.']); + $conf['params.'] = array_merge((array)$typeConf['default.']['params.'], (array)$conf['params.']); + $conf['attributes.'] = array_merge((array)$typeConf['default.']['attributes.'], (array)$conf['attributes.']); $conf['embedParams'] = 'flashvars, params, attributes'; // Hook for manipulating the conf array, it's needed for some players like flowplayer if (is_array($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/hooks/class.tx_cms_mediaitems.php']['swfParamTransform'])) { diff --git a/typo3/sysext/frontend/Classes/ContentObject/FormContentObject.php b/typo3/sysext/frontend/Classes/ContentObject/FormContentObject.php index 84265a55f8c231c255b75c2b346a9b51887068af..fc5c2c0c530af59185f8e94b8c7c691f14a6c3cb 100644 --- a/typo3/sysext/frontend/Classes/ContentObject/FormContentObject.php +++ b/typo3/sysext/frontend/Classes/ContentObject/FormContentObject.php @@ -78,7 +78,7 @@ class FormContentObject extends \TYPO3\CMS\Frontend\ContentObject\AbstractConten if (is_array($singleKeyArray['valueArray.'])) { $temp_accumulated = array(); foreach ($singleKeyArray['valueArray.'] as $singleKey => $singleKey_valueArray) { - if (is_array($singleKey_valueArray) && (int)$singleKey . '.' === (string) $singleKey) { + if (is_array($singleKey_valueArray) && (int)$singleKey . '.' === (string)$singleKey) { $temp_valueArray = array(); $valueArrayLabel = isset($singleKey_valueArray['label.']) ? $this->cObj->stdWrap($singleKey_valueArray['label'], $singleKey_valueArray['label.']) : $singleKey_valueArray['label']; list($temp_valueArray[0]) = explode('=', $valueArrayLabel); @@ -425,7 +425,7 @@ class FormContentObject extends \TYPO3\CMS\Frontend\ContentObject\AbstractConten $modeParameters = array(); } // Adding evaluation based on settings: - switch ((string) $modeParameters[0]) { + switch ((string)$modeParameters[0]) { case 'EREG': $fieldlist[] = '_EREG'; $fieldlist[] = $modeParameters[1]; diff --git a/typo3/sysext/frontend/Classes/ContentObject/MediaContentObject.php b/typo3/sysext/frontend/Classes/ContentObject/MediaContentObject.php index bd86abdcfe1dae2e0e09bd9015c1095e31f1dee1..dcb6fef46afce3bf3759053c8224bdef854a82ab 100644 --- a/typo3/sysext/frontend/Classes/ContentObject/MediaContentObject.php +++ b/typo3/sysext/frontend/Classes/ContentObject/MediaContentObject.php @@ -163,7 +163,7 @@ class MediaContentObject extends \TYPO3\CMS\Frontend\ContentObject\AbstractConte } if ($renderType !== 'qt' && $renderType !== 'embed' && $conf['type'] == 'video') { if (isset($conf['file']) && (strpos($conf['file'], '.swf') !== FALSE || strpos($conf['file'], '://') !== FALSE && strpos(\TYPO3\CMS\Core\Utility\GeneralUtility::getUrl($conf['file'], 2), 'application/x-shockwave-flash') !== FALSE)) { - $conf = array_merge((array) $conf['mimeConf.']['swfobject.'], $conf); + $conf = array_merge((array)$conf['mimeConf.']['swfobject.'], $conf); $conf[$conf['type'] . '.']['player'] = strpos($conf['file'], '://') === FALSE ? 'http://' . $conf['file'] : $conf['file']; $conf['installUrl'] = 'null'; $conf['forcePlayer'] = 0; @@ -182,30 +182,30 @@ class MediaContentObject extends \TYPO3\CMS\Frontend\ContentObject\AbstractConte } switch ($renderType) { case 'flowplayer': - $conf[$conf['type'] . '.'] = array_merge((array) $conf['mimeConf.']['flowplayer.'][($conf['type'] . '.')], $typeConf); - $conf = array_merge((array) $conf['mimeConf.']['flowplayer.'], $conf); + $conf[$conf['type'] . '.'] = array_merge((array)$conf['mimeConf.']['flowplayer.'][($conf['type'] . '.')], $typeConf); + $conf = array_merge((array)$conf['mimeConf.']['flowplayer.'], $conf); unset($conf['mimeConf.']); - $conf['attributes.'] = array_merge((array) $conf['attributes.'], $conf['predefined']); - $conf['params.'] = array_merge((array) $conf['params.'], $conf['predefined']); - $conf['flashvars.'] = array_merge((array) $conf['flashvars.'], $conf['predefined']); + $conf['attributes.'] = array_merge((array)$conf['attributes.'], $conf['predefined']); + $conf['params.'] = array_merge((array)$conf['params.'], $conf['predefined']); + $conf['flashvars.'] = array_merge((array)$conf['flashvars.'], $conf['predefined']); $content = $this->cObj->FLOWPLAYER($conf); break; case 'swf': - $conf[$conf['type'] . '.'] = array_merge((array) $conf['mimeConf.']['swfobject.'][($conf['type'] . '.')], $typeConf); - $conf = array_merge((array) $conf['mimeConf.']['swfobject.'], $conf); + $conf[$conf['type'] . '.'] = array_merge((array)$conf['mimeConf.']['swfobject.'][($conf['type'] . '.')], $typeConf); + $conf = array_merge((array)$conf['mimeConf.']['swfobject.'], $conf); unset($conf['mimeConf.']); - $conf['flashvars.'] = array_merge((array) $conf['flashvars.'], $conf['predefined']); + $conf['flashvars.'] = array_merge((array)$conf['flashvars.'], $conf['predefined']); $content = $this->cObj->SWFOBJECT($conf); break; case 'qt': $conf[$conf['type'] . '.'] = array_merge($conf['mimeConf.']['swfobject.'][$conf['type'] . '.'], $typeConf); $conf = array_merge($conf['mimeConf.']['qtobject.'], $conf); unset($conf['mimeConf.']); - $conf['params.'] = array_merge((array) $conf['params.'], $conf['predefined']); + $conf['params.'] = array_merge((array)$conf['params.'], $conf['predefined']); $content = $this->cObj->QTOBJECT($conf); break; case 'embed': - $paramsArray = array_merge((array) $typeConf['default.']['params.'], (array) $conf['params.'], $conf['predefined']); + $paramsArray = array_merge((array)$typeConf['default.']['params.'], (array)$conf['params.'], $conf['predefined']); $conf['params'] = ''; foreach ($paramsArray as $key => $value) { $conf['params'] .= $key . '=' . $value . LF; diff --git a/typo3/sysext/frontend/Classes/ContentObject/MultimediaContentObject.php b/typo3/sysext/frontend/Classes/ContentObject/MultimediaContentObject.php index abbec44cd5f127b4d7801c99e0937d0905eae7f4..ecb50b562f2c978f74c0ba72dc2eb0dd68d611a9 100644 --- a/typo3/sysext/frontend/Classes/ContentObject/MultimediaContentObject.php +++ b/typo3/sysext/frontend/Classes/ContentObject/MultimediaContentObject.php @@ -71,7 +71,7 @@ class MultimediaContentObject extends \TYPO3\CMS\Frontend\ContentObject\Abstract $parts = explode('=', $l); $parameter = strtolower(trim($parts[0])); $value = trim($parts[1]); - if ((string) $value != '') { + if ((string)$value != '') { $parArray[$parameter] = $parameter . '="' . htmlspecialchars($value) . '"'; } else { unset($parArray[$parameter]); diff --git a/typo3/sysext/frontend/Classes/ContentObject/QuicktimeObjectContentObject.php b/typo3/sysext/frontend/Classes/ContentObject/QuicktimeObjectContentObject.php index 763ce30ce28d5d789c7478d75d11109b893d4a26..ba1b2a191e4c3b031734946563394ee0db0ae222 100644 --- a/typo3/sysext/frontend/Classes/ContentObject/QuicktimeObjectContentObject.php +++ b/typo3/sysext/frontend/Classes/ContentObject/QuicktimeObjectContentObject.php @@ -53,7 +53,7 @@ class QuicktimeObjectContentObject extends \TYPO3\CMS\Frontend\ContentObject\Abs $GLOBALS['TSFE']->register['MMQTID'] = $replaceElementIdString; $qtObject = 'QTObject' . $replaceElementIdString; // Merge with default parameters - $conf['params.'] = array_merge((array) $typeConf['default.']['params.'], (array) $conf['params.']); + $conf['params.'] = array_merge((array)$typeConf['default.']['params.'], (array)$conf['params.']); if (is_array($conf['params.'])) { \TYPO3\CMS\Core\Utility\GeneralUtility::remapArrayKeys($conf['params.'], $typeConf['mapping.']['params.']); foreach ($conf['params.'] as $key => $value) { diff --git a/typo3/sysext/frontend/Classes/ContentObject/ShockwaveFlashObjectContentObject.php b/typo3/sysext/frontend/Classes/ContentObject/ShockwaveFlashObjectContentObject.php index b1915205bd866b550ed4bf6bc6db90c8c467e8cd..b97158ff28ee7f86525e6e617d1e65b3e2174287 100644 --- a/typo3/sysext/frontend/Classes/ContentObject/ShockwaveFlashObjectContentObject.php +++ b/typo3/sysext/frontend/Classes/ContentObject/ShockwaveFlashObjectContentObject.php @@ -73,9 +73,9 @@ class ShockwaveFlashObjectContentObject extends \TYPO3\CMS\Frontend\ContentObjec $conf['filename'] = $filename; $conf['prefix'] = $prefix; // Merge with default parameters - $conf['flashvars.'] = array_merge((array) $typeConf['default.']['flashvars.'], (array) $conf['flashvars.']); - $conf['params.'] = array_merge((array) $typeConf['default.']['params.'], (array) $conf['params.']); - $conf['attributes.'] = array_merge((array) $typeConf['default.']['attributes.'], (array) $conf['attributes.']); + $conf['flashvars.'] = array_merge((array)$typeConf['default.']['flashvars.'], (array)$conf['flashvars.']); + $conf['params.'] = array_merge((array)$typeConf['default.']['params.'], (array)$conf['params.']); + $conf['attributes.'] = array_merge((array)$typeConf['default.']['attributes.'], (array)$conf['attributes.']); $conf['embedParams'] = 'flashvars, params, attributes'; // Hook for manipulating the conf array, it's needed for some players like flowplayer if (is_array($GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/hooks/class.tx_cms_mediaitems.php']['swfParamTransform'])) { diff --git a/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php b/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php index 2a276f166d9711425b89f56e764f401a8ce09232..b2ab0b21f68b4575efaf941cc28c4b259b29916f 100644 --- a/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php +++ b/typo3/sysext/frontend/Classes/Controller/TypoScriptFrontendController.php @@ -874,7 +874,7 @@ class TypoScriptFrontendController { } $this->cHash = $cHash; $this->jumpurl = $jumpurl; - $this->MP = $this->TYPO3_CONF_VARS['FE']['enable_mount_pids'] ? (string) $MP : ''; + $this->MP = $this->TYPO3_CONF_VARS['FE']['enable_mount_pids'] ? (string)$MP : ''; $this->RDCT = $RDCT; $this->clientInfo = GeneralUtility::clientInfo(); $this->uniqueString = md5(microtime()); @@ -2389,8 +2389,8 @@ class TypoScriptFrontendController { $hashParameters = array( 'id' => (int)$this->id, 'type' => (int)$this->type, - 'gr_list' => (string) $this->gr_list, - 'MP' => (string) $this->MP, + 'gr_list' => (string)$this->gr_list, + 'MP' => (string)$this->MP, 'cHash' => $this->cHash_array, 'domainStartPage' => $this->domainStartPage ); @@ -2554,7 +2554,7 @@ class TypoScriptFrontendController { if (GeneralUtility::hideIfNotTranslated($this->page['l18n_cfg'])) { $this->pageNotFoundAndExit('Page is not available in the requested language.'); } else { - switch ((string) $this->sys_language_mode) { + switch ((string)$this->sys_language_mode) { case 'strict': $this->pageNotFoundAndExit('Page is not available in the requested language (strict).'); break; @@ -2856,16 +2856,16 @@ class TypoScriptFrontendController { public function jumpUrl() { if ($this->jumpurl) { if (GeneralUtility::_GP('juSecure')) { - $locationData = (string) GeneralUtility::_GP('locationData'); + $locationData = (string)GeneralUtility::_GP('locationData'); // Need a type cast here because mimeType is optional! - $mimeType = (string) GeneralUtility::_GP('mimeType'); + $mimeType = (string)GeneralUtility::_GP('mimeType'); $hArr = array( $this->jumpurl, $locationData, $mimeType ); $calcJuHash = GeneralUtility::hmac(serialize($hArr)); - $juHash = (string) GeneralUtility::_GP('juHash'); + $juHash = (string)GeneralUtility::_GP('juHash'); if ($juHash === $calcJuHash) { if ($this->locDataCheck($locationData)) { // 211002 - goes with cObj->filelink() rawurlencode() of filenames so spaces can be allowed. @@ -2964,7 +2964,7 @@ class TypoScriptFrontendController { */ public function calculateLinkVars() { $this->linkVars = ''; - $linkVars = GeneralUtility::trimExplode(',', (string) $this->config['config']['linkVars']); + $linkVars = GeneralUtility::trimExplode(',', (string)$this->config['config']['linkVars']); if (empty($linkVars)) { return; } diff --git a/typo3/sysext/frontend/Classes/Imaging/GifBuilder.php b/typo3/sysext/frontend/Classes/Imaging/GifBuilder.php index 3b2ca6ceeaaddfcc93bc311f9d7a33fbe9199ab3..e14711a0940ceeb9046863901b852cce12f50a23 100644 --- a/typo3/sysext/frontend/Classes/Imaging/GifBuilder.php +++ b/typo3/sysext/frontend/Classes/Imaging/GifBuilder.php @@ -568,7 +568,7 @@ class GifBuilder extends \TYPO3\CMS\Core\Imaging\GraphicalFunctions { $conf['text'] = substr($conf['text'], 0, $tlen); } } - if ((string) $conf['text'] != '') { + if ((string)$conf['text'] != '') { // Char range map thingie: $fontBaseName = basename($conf['fontFile']); if (is_array($this->charRangeMap[$fontBaseName])) { diff --git a/typo3/sysext/frontend/Classes/Page/PageGenerator.php b/typo3/sysext/frontend/Classes/Page/PageGenerator.php index 87c92bfa1d6d99d5de94b821c1004c24e2e59f99..6b22465034aec68d199c081b3dacd28e6625e36d 100644 --- a/typo3/sysext/frontend/Classes/Page/PageGenerator.php +++ b/typo3/sysext/frontend/Classes/Page/PageGenerator.php @@ -111,7 +111,7 @@ class PageGenerator { $GLOBALS['TSFE']->dtdAllowsFrames = FALSE; if ($GLOBALS['TSFE']->config['config']['doctype']) { if (in_array( - (string) $GLOBALS['TSFE']->config['config']['doctype'], + (string)$GLOBALS['TSFE']->config['config']['doctype'], array('xhtml_trans', 'xhtml_frames', 'xhtml_basic', 'xhtml_2', 'html5'), TRUE) ) { @@ -127,7 +127,7 @@ class PageGenerator { if ($GLOBALS['TSFE']->config['config']['xhtmlDoctype']) { $GLOBALS['TSFE']->xhtmlDoctype = $GLOBALS['TSFE']->config['config']['xhtmlDoctype']; // Checking XHTML-docytpe - switch ((string) $GLOBALS['TSFE']->config['config']['xhtmlDoctype']) { + switch ((string)$GLOBALS['TSFE']->config['config']['xhtmlDoctype']) { case 'xhtml_trans': case 'xhtml_strict': @@ -277,7 +277,7 @@ class PageGenerator { $docTypeParts = array(); $xmlDocument = TRUE; // Part 1: XML prologue - switch ((string) $GLOBALS['TSFE']->config['config']['xmlprologue']) { + switch ((string)$GLOBALS['TSFE']->config['config']['xmlprologue']) { case 'none': $xmlDocument = FALSE; $GLOBALS['TSFE']->config['config']['xhtml_cleaning'] = 'none'; diff --git a/typo3/sysext/frontend/Classes/Page/PageRepository.php b/typo3/sysext/frontend/Classes/Page/PageRepository.php index c355cd2ec79f336b0e072e9d77ae1e5e9b846ca2..ea27a212b3c294f7d0cd82169ea56cbbbeea2e68 100644 --- a/typo3/sysext/frontend/Classes/Page/PageRepository.php +++ b/typo3/sysext/frontend/Classes/Page/PageRepository.php @@ -281,7 +281,7 @@ class PageRepository { * Returns a pagerow for the page with alias $alias * * @param string $alias The alias to look up the page uid for. - * @return int Returns page uid (integer) if found, otherwise 0 (zero) + * @return int Returns page uid (int) if found, otherwise 0 (zero) * @see \TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController::checkAndSetAlias(), ContentObjectRenderer::typoLink() */ public function getPageIdFromAlias($alias) { diff --git a/typo3/sysext/frontend/Classes/Plugin/AbstractPlugin.php b/typo3/sysext/frontend/Classes/Plugin/AbstractPlugin.php index 1009aee377d551d2f12b54b18e59952a141c9776..36a0fff5c506ebbc895db6ab96798b61a137b3fa 100644 --- a/typo3/sysext/frontend/Classes/Plugin/AbstractPlugin.php +++ b/typo3/sysext/frontend/Classes/Plugin/AbstractPlugin.php @@ -400,11 +400,11 @@ class AbstractPlugin { if ($this->prefixId) { if ($cache) { $overrulePIvars = $uid ? array('showUid' => $uid) : array(); - $overrulePIvars = array_merge($overrulePIvars, (array) $mergeArr); + $overrulePIvars = array_merge($overrulePIvars, (array)$mergeArr); $str = $this->pi_linkTP($str, array($this->prefixId => $overrulePIvars), $cache, $altPageId); } else { $overrulePIvars = array('showUid' => $uid ?: ''); - $overrulePIvars = array_merge($overrulePIvars, (array) $mergeArr); + $overrulePIvars = array_merge($overrulePIvars, (array)$mergeArr); $str = $this->pi_linkTP_keepPIvars($str, $overrulePIvars, $cache, 0, $altPageId); } // If urlOnly flag, return only URL as it has recently be generated. diff --git a/typo3/sysext/impexp/Classes/Controller/ImportExportController.php b/typo3/sysext/impexp/Classes/Controller/ImportExportController.php index 040f74226dab8c852a63aeebfdeca2e6ee303dc3..98b13cfccf38c7f6d114ef7b56516f458e172fde 100644 --- a/typo3/sysext/impexp/Classes/Controller/ImportExportController.php +++ b/typo3/sysext/impexp/Classes/Controller/ImportExportController.php @@ -106,7 +106,7 @@ class ImportExportController extends \TYPO3\CMS\Backend\Module\BaseScriptClass { // Input data grabbed: $inData = GeneralUtility::_GP('tx_impexp'); $this->checkUpload(); - switch ((string) $inData['action']) { + switch ((string)$inData['action']) { case 'export': // Finally: If upload went well, set the new file as the thumbnail in the $inData array: if (!empty($this->uploadedFiles[0])) { @@ -161,7 +161,7 @@ class ImportExportController extends \TYPO3\CMS\Backend\Module\BaseScriptClass { } // Input data grabbed: $inData = GeneralUtility::_GP('tx_impexp'); - if ((string) $inData['action'] == 'import') { + if ((string)$inData['action'] == 'import') { if ($this->id && is_array($this->pageinfo) || $this->getBackendUser()->user['admin'] && !$this->id) { if (is_array($this->pageinfo) && $this->pageinfo['uid']) { // View @@ -214,9 +214,9 @@ class ImportExportController extends \TYPO3\CMS\Backend\Module\BaseScriptClass { $this->export->init(0, 'export'); $this->export->setCharset($this->lang->charSet); $this->export->maxFileSize = $inData['maxFileSize'] * 1024; - $this->export->excludeMap = (array) $inData['exclude']; - $this->export->softrefCfg = (array) $inData['softrefCfg']; - $this->export->extensionDependencies = (array) $inData['extension_dep']; + $this->export->excludeMap = (array)$inData['exclude']; + $this->export->softrefCfg = (array)$inData['softrefCfg']; + $this->export->extensionDependencies = (array)$inData['extension_dep']; $this->export->showStaticRelations = $inData['showStaticRelations']; $this->export->includeExtFileResources = !$inData['excludeHTMLfileResources']; // Static tables: @@ -339,7 +339,7 @@ class ImportExportController extends \TYPO3\CMS\Backend\Module\BaseScriptClass { // If the download button is clicked, return file if ($inData['download_export'] || $inData['save_export']) { - switch ((string) $inData['filetype']) { + switch ((string)$inData['filetype']) { case 'xml': $out = $this->export->compileMemoryToFileContent('xml'); $fExt = '.xml'; @@ -1213,11 +1213,11 @@ class ImportExportController extends \TYPO3\CMS\Backend\Module\BaseScriptClass { if (isset($presetData['merge'])) { // Merge records in: if (is_array($inData_temp['record'])) { - $inData['record'] = array_merge((array) $inData['record'], $inData_temp['record']); + $inData['record'] = array_merge((array)$inData['record'], $inData_temp['record']); } // Merge lists in: if (is_array($inData_temp['list'])) { - $inData['list'] = array_merge((array) $inData['list'], $inData_temp['list']); + $inData['list'] = array_merge((array)$inData['list'], $inData_temp['list']); } } else { $msg = 'Preset #' . $preset['uid'] . ' loaded!'; diff --git a/typo3/sysext/impexp/Classes/ImportExport.php b/typo3/sysext/impexp/Classes/ImportExport.php index 9668e4c4ea835c5e8b09bf21209eb4e2ef0c3135..55ca715693c107b360dbd522f9b16ea650f0172f 100644 --- a/typo3/sysext/impexp/Classes/ImportExport.php +++ b/typo3/sysext/impexp/Classes/ImportExport.php @@ -2092,7 +2092,7 @@ class ImportExport { } // Setting db/file blank: foreach ($this->dat['records'][$table . ':' . $uid]['rels'] as $field => $config) { - switch ((string) $config['type']) { + switch ((string)$config['type']) { case 'db': case 'file': @@ -2225,7 +2225,7 @@ class ImportExport { if ($table === 'sys_file_reference' && $field === 'uid_local') { continue; } - switch ((string) $config['type']) { + switch ((string)$config['type']) { case 'db': if (is_array($config['itemArray']) && count($config['itemArray'])) { $itemConfig = $GLOBALS['TCA'][$table]['columns'][$field]['config']; @@ -2417,7 +2417,7 @@ class ImportExport { $thisNewUid = BackendUtility::wsMapId($table, $this->import_mapId[$table][$uid]); // Traverse relation fields of each record foreach ($this->dat['records'][$table . ':' . $uid]['rels'] as $field => $config) { - switch ((string) $config['type']) { + switch ((string)$config['type']) { case 'flex': // Get XML content and set as default value (string, non-processed): $updateData[$table][$thisNewUid][$field] = $this->dat['records'][$table . ':' . $uid]['data'][$field]; @@ -2630,7 +2630,7 @@ class ImportExport { // Default is current token value: $insertValue = $cfg['subst']['tokenValue']; // Based on mode: - switch ((string) $this->softrefCfg[$tokenID]['mode']) { + switch ((string)$this->softrefCfg[$tokenID]['mode']) { case 'exclude': // Exclude is a simple passthrough of the value break; @@ -2640,7 +2640,7 @@ class ImportExport { break; default: // Mapping IDs/creating files: Based on type, look up new value: - switch ((string) $cfg['subst']['type']) { + switch ((string)$cfg['subst']['type']) { case 'file': // Create / Overwrite file: $insertValue = $this->processSoftReferences_saveFile($cfg['subst']['relFileName'], $cfg, $table, $uid); @@ -3259,10 +3259,10 @@ class ImportExport { * @return void */ public function loadInit() { - $this->relStaticTables = (array) $this->dat['header']['relStaticTables']; - $this->excludeMap = (array) $this->dat['header']['excludeMap']; - $this->softrefCfg = (array) $this->dat['header']['softrefCfg']; - $this->extensionDependencies = (array) $this->dat['header']['extensionDependencies']; + $this->relStaticTables = (array)$this->dat['header']['relStaticTables']; + $this->excludeMap = (array)$this->dat['header']['excludeMap']; + $this->softrefCfg = (array)$this->dat['header']['softrefCfg']; + $this->extensionDependencies = (array)$this->dat['header']['extensionDependencies']; $this->fixCharsets(); if ( isset($this->dat['header']['meta']['TYPO3_version']) @@ -3580,7 +3580,7 @@ class ImportExport { } } } - $pInfo['preCode'] = $preCode . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIconForRecord($table, (array) $this->dat['records'][($table . ':' . $uid)]['data'], array('title' => htmlspecialchars(($table . ':' . $uid)))); + $pInfo['preCode'] = $preCode . \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIconForRecord($table, (array)$this->dat['records'][($table . ':' . $uid)]['data'], array('title' => htmlspecialchars(($table . ':' . $uid)))); $pInfo['title'] = htmlspecialchars($record['title']); // View page: if ($table === 'pages') { @@ -4004,7 +4004,7 @@ class ImportExport { public function getRecordPath($pid) { if (!isset($this->cache_getRecordPath[$pid])) { $clause = $GLOBALS['BE_USER']->getPagePermsClause(1); - $this->cache_getRecordPath[$pid] = (string) BackendUtility::getRecordPath($pid, $clause, 20); + $this->cache_getRecordPath[$pid] = (string)BackendUtility::getRecordPath($pid, $clause, 20); } return $this->cache_getRecordPath[$pid]; } diff --git a/typo3/sysext/indexed_search/Classes/Controller/SearchController.php b/typo3/sysext/indexed_search/Classes/Controller/SearchController.php index 70c9cf5a131707b1cbe19d75c2a6c7ecc5dc09f9..cc3b1d1315f46397e0a7227b09a126898ce8996a 100644 --- a/typo3/sysext/indexed_search/Classes/Controller/SearchController.php +++ b/typo3/sysext/indexed_search/Classes/Controller/SearchController.php @@ -443,7 +443,7 @@ class SearchController extends \TYPO3\CMS\Extbase\Mvc\Controller\ActionControlle * @todo can this be a ViewHelper? */ protected function makeRating($row) { - switch ((string) $this->searchData['sortOrder']) { + switch ((string)$this->searchData['sortOrder']) { case 'rank_count': return $row['order_val'] . ' ' . \TYPO3\CMS\Extbase\Utility\LocalizationUtility::translate('result.ratingMatches', 'indexed_search'); break; @@ -485,7 +485,7 @@ class SearchController extends \TYPO3\CMS\Extbase\Mvc\Controller\ActionControlle protected function makeLanguageIndication($row) { $output = ' '; // If search result is a TYPO3 page: - if ((string) $row['item_type'] === '0') { + if ((string)$row['item_type'] === '0') { // If TypoScript is used to render the flag: if (is_array($this->settings['flagRendering.'])) { /** @var \TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer $cObj */ @@ -1124,7 +1124,7 @@ class SearchController extends \TYPO3\CMS\Extbase\Mvc\Controller\ActionControlle */ protected function linkPage($pageUid, $linkText, $row = array(), $markUpSwParams = array()) { // Parameters for link - $urlParameters = (array) unserialize($row['cHashParams']); + $urlParameters = (array)unserialize($row['cHashParams']); // Add &type and &MP variable: if ($row['data_page_mp']) { $urlParameters['MP'] = $row['data_page_mp']; diff --git a/typo3/sysext/indexed_search/Classes/Controller/SearchFormController.php b/typo3/sysext/indexed_search/Classes/Controller/SearchFormController.php index f0852a833974533546461d1f562092fc6b1c3d5f..cb68c7f6e83ea692f579cdadbf2c5008185b7b30 100644 --- a/typo3/sysext/indexed_search/Classes/Controller/SearchFormController.php +++ b/typo3/sysext/indexed_search/Classes/Controller/SearchFormController.php @@ -485,12 +485,12 @@ class SearchFormController extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin { // we are sure they are not displayed in this request? // This will slow down your page rendering, but it allows // precise search result counters. - $calculateExactCount = (bool) $this->conf['search.']['exactCount']; + $calculateExactCount = (bool)$this->conf['search.']['exactCount']; $lastResultNumberOnPreviousPage = $currentPageNumber * $this->piVars['results']; $firstResultNumberOnNextPage = ($currentPageNumber + 1) * $this->piVars['results']; $lastResultNumberToAnalyze = ($currentPageNumber + 1) * $this->piVars['results'] + $this->piVars['results']; // Now, traverse result and put the rows to be displayed into an array - // Each row should contain the fields from 'ISEC.*, IP.*' combined + artificial fields "show_resume" (boolean) and "result_number" (counter) + // Each row should contain the fields from 'ISEC.*, IP.*' combined + artificial fields "show_resume" (bool) and "result_number" (counter) while (FALSE !== ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res))) { if (!$this->checkExistance($row)) { // Check if the record is still available or if it has been deleted meanwhile. @@ -727,7 +727,7 @@ class SearchFormController extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin { foreach ($sWArr as $k => $v) { // Making the query for a single search word based on the search-type $sWord = $v['sword']; - $theType = (string) $this->piVars['type']; + $theType = (string)$this->piVars['type']; if (strstr($sWord, ' ')) { // If there are spaces in the search-word, make a full text search instead. $theType = 20; @@ -902,7 +902,7 @@ class SearchFormController extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin { } // If no match above, test the static types: if (!$match) { - switch ((string) $this->piVars['sections']) { + switch ((string)$this->piVars['sections']) { case '-1': // '-1' => 'Only this page', $out .= ' AND ISEC.page_id=' . $GLOBALS['TSFE']->id; @@ -926,7 +926,7 @@ class SearchFormController extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin { * @return string AND statement for selection of media type */ public function mediaTypeWhere() { - switch ((string) $this->piVars['media']) { + switch ((string)$this->piVars['media']) { case '0': // '0' => 'Kun TYPO3 sider', $out = ' AND IP.item_type=' . $GLOBALS['TYPO3_DB']->fullQuoteStr('0', 'index_phash'); @@ -1080,7 +1080,7 @@ class SearchFormController extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin { } else { // Otherwise, if sorting are done with the pages table or other fields, there is no need for joining with the rel/word tables: $orderBy = ''; - switch ((string) $this->piVars['order']) { + switch ((string)$this->piVars['order']) { case 'title': $orderBy = 'IP.item_title' . $this->isDescending(); break; @@ -1257,7 +1257,7 @@ class SearchFormController extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin { foreach (GeneralUtility::trimExplode(',', $this->hiddenFieldList) as $fieldName) { $hiddenFieldMarkerArray = array(); $hiddenFieldMarkerArray['###HIDDEN_FIELDNAME###'] = $this->prefixId . '[' . $fieldName . ']'; - $hiddenFieldMarkerArray['###HIDDEN_VALUE###'] = htmlspecialchars((string) $this->piVars[$fieldName]); + $hiddenFieldMarkerArray['###HIDDEN_VALUE###'] = htmlspecialchars((string)$this->piVars[$fieldName]); $hiddenFieldArr[$fieldName] = $this->cObj->substituteMarkerArrayCached($hiddenFieldCode, $hiddenFieldMarkerArray, array(), array()); } // Extended search @@ -1748,7 +1748,7 @@ class SearchFormController extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin { * @return string String showing ranking value */ public function makeRating($row) { - switch ((string) $this->piVars['order']) { + switch ((string)$this->piVars['order']) { case 'rank_count': // Number of occurencies on page return $row['order_val'] . ' ' . $this->pi_getLL('maketitle_matches'); @@ -1978,7 +1978,7 @@ class SearchFormController extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin { */ public function makeLanguageIndication($row) { // If search result is a TYPO3 page: - if ((string) $row['item_type'] === '0') { + if ((string)$row['item_type'] === '0') { // If TypoScript is used to render the flag: if (is_array($this->conf['flagRendering.'])) { $this->cObj->setCurrentVal($row['sys_language_uid']); @@ -2012,7 +2012,7 @@ class SearchFormController extends \TYPO3\CMS\Frontend\Plugin\AbstractPlugin { */ public function linkPage($id, $str, $row = array(), $markUpSwParams = array()) { // Parameters for link: - $urlParameters = (array) unserialize($row['cHashParams']); + $urlParameters = (array)unserialize($row['cHashParams']); // Add &type and &MP variable: if ($row['data_page_type']) { $urlParameters['type'] = $row['data_page_type']; diff --git a/typo3/sysext/indexed_search/Classes/Domain/Repository/IndexSearchRepository.php b/typo3/sysext/indexed_search/Classes/Domain/Repository/IndexSearchRepository.php index fc7a4c31b9a5b1061dc5ba73241e833f16900921..24ac17a267ff53db6daff1545c988f0f83704fa4 100644 --- a/typo3/sysext/indexed_search/Classes/Domain/Repository/IndexSearchRepository.php +++ b/typo3/sysext/indexed_search/Classes/Domain/Repository/IndexSearchRepository.php @@ -154,7 +154,7 @@ class IndexSearchRepository { // Will hold the results rows for display. // Now, traverse result and put the rows to be displayed into an array // Each row should contain the fields from 'ISEC.*, IP.*' combined - // + artificial fields "show_resume" (boolean) and "result_number" (counter) + // + artificial fields "show_resume" (bool) and "result_number" (counter) while ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res)) { // Set first row if (!$c) { @@ -253,7 +253,7 @@ class IndexSearchRepository { foreach ($searchWords as $k => $v) { // Making the query for a single search word based on the search-type $sWord = $v['sword']; - $theType = (string) $this->searchType; + $theType = (string)$this->searchType; // If there are spaces in the search-word, make a full text search instead. if (strstr($sWord, ' ')) { $theType = 20; @@ -436,7 +436,7 @@ class IndexSearchRepository { } // If no match above, test the static types: if (!$match) { - switch ((string) $this->sections) { + switch ((string)$this->sections) { case '-1': $whereClause .= ' AND ISEC.page_id=' . $GLOBALS['TSFE']->id; break; @@ -611,7 +611,7 @@ class IndexSearchRepository { // Otherwise, if sorting are done with the pages table or other fields, // there is no need for joining with the rel/word tables: $orderBy = ''; - switch ((string) $this->sortOrder) { + switch ((string)$this->sortOrder) { case 'title': $orderBy = 'IP.item_title' . $this->getDescendingSortOrderFlag(); break; diff --git a/typo3/sysext/indexed_search/Classes/FileContentParser.php b/typo3/sysext/indexed_search/Classes/FileContentParser.php index b412492ecfa0c59249c25b45d347d041538e8548..d14e02fb748ab64fac91cc2c9b1302d0dae7caa7 100644 --- a/typo3/sysext/indexed_search/Classes/FileContentParser.php +++ b/typo3/sysext/indexed_search/Classes/FileContentParser.php @@ -389,7 +389,7 @@ class FileContentParser { */ public function isMultiplePageExtension($extension) { // Switch on file extension: - switch ((string) $extension) { + switch ((string)$extension) { case 'pdf': return TRUE; break; diff --git a/typo3/sysext/indexed_search/Classes/Hook/CrawlerHook.php b/typo3/sysext/indexed_search/Classes/Hook/CrawlerHook.php index 6f5f8d48c873ea9c9699115ccb7d908555ab1541..4bf17dd0829b3d2f912fe6fb9ad310b600244cb4 100644 --- a/typo3/sysext/indexed_search/Classes/Hook/CrawlerHook.php +++ b/typo3/sysext/indexed_search/Classes/Hook/CrawlerHook.php @@ -291,7 +291,7 @@ class CrawlerHook { $directoryList = GeneralUtility::get_dirs($readpath); if (is_array($directoryList) && $params['depth'] < $cfgRec['depth']) { foreach ($directoryList as $subdir) { - if ((string) $subdir != '') { + if ((string)$subdir != '') { $files[] = $readpath . $subdir . '/'; } } diff --git a/typo3/sysext/indexed_search/Classes/Indexer.php b/typo3/sysext/indexed_search/Classes/Indexer.php index 7f4665bb9c2f6aa8fdc544bff91f62229185d17f..fffcf0646023e5dc0cb0f57cfb9603fc76df8751 100644 --- a/typo3/sysext/indexed_search/Classes/Indexer.php +++ b/typo3/sysext/indexed_search/Classes/Indexer.php @@ -247,11 +247,11 @@ class Indexer { $this->conf = array(); // Information about page for which the indexing takes place $this->conf['id'] = $id; - // Page id (integer) + // Page id (int) $this->conf['type'] = $type; - // Page type (integer) + // Page type (int) $this->conf['sys_language_uid'] = $sys_language_uid; - // sys_language UID of the language of the indexing (integer) + // sys_language UID of the language of the indexing (int) $this->conf['MP'] = $MP; // MP variable, if any (Mount Points) (string) $this->conf['gr_list'] = '0,-1'; @@ -1330,7 +1330,7 @@ class Indexer { // TYPO3 page 'item_title' => $this->contentParts['title'], 'item_description' => $this->bodyDescription($this->contentParts), - 'item_mtime' => (int) $this->conf['mtime'], + 'item_mtime' => (int)$this->conf['mtime'], 'item_size' => strlen($this->conf['content']), 'tstamp' => $GLOBALS['EXEC_TIME'], 'crdate' => $GLOBALS['EXEC_TIME'], @@ -1916,13 +1916,13 @@ class Indexer { 'id' => (int)$this->conf['id'], 'type' => (int)$this->conf['type'], 'sys_lang' => (int)$this->conf['sys_language_uid'], - 'MP' => (string) $this->conf['MP'], + 'MP' => (string)$this->conf['MP'], 'cHash' => $this->cHashParams ); // Set grouping hash (Identifies a "page" combined of id, type, language, mountpoint and cHash parameters): $this->hash['phash_grouping'] = \TYPO3\CMS\IndexedSearch\Utility\IndexedSearchUtility::md5inthash(serialize($hArray)); // Add gr_list and set plain phash (Subdivision where special page composition based on login is taken into account as well. It is expected that such pages are normally similar regardless of the login.) - $hArray['gr_list'] = (string) $this->conf['gr_list']; + $hArray['gr_list'] = (string)$this->conf['gr_list']; $this->hash['phash'] = \TYPO3\CMS\IndexedSearch\Utility\IndexedSearchUtility::md5inthash(serialize($hArray)); } diff --git a/typo3/sysext/indexed_search_mysql/Classes/Hook/MysqlFulltextIndexHook.php b/typo3/sysext/indexed_search_mysql/Classes/Hook/MysqlFulltextIndexHook.php index c17b2a6020d6ee0a13191339ad98a8d85d546617..3f5a1fc766fdfcf7d46ab14ed6186948cd19b6e9 100644 --- a/typo3/sysext/indexed_search_mysql/Classes/Hook/MysqlFulltextIndexHook.php +++ b/typo3/sysext/indexed_search_mysql/Classes/Hook/MysqlFulltextIndexHook.php @@ -67,7 +67,7 @@ class MysqlFulltextIndexHook { // This holds the result if the search is natural (doesn't contain any boolean operators) $booleanSearchString = ''; // This holds the result if the search is boolen (contains +/-/| operators) - $searchType = (string) $this->pObj->piVars['type']; + $searchType = (string)$this->pObj->piVars['type']; // Traverse searchwords and prefix them with corresponding operator foreach ($searchWordArray as $searchWordData) { // Making the query for a single search word based on the search-type diff --git a/typo3/sysext/install/Classes/Controller/Action/Tool/AllConfiguration.php b/typo3/sysext/install/Classes/Controller/Action/Tool/AllConfiguration.php index 7888f999da0ff90ee3d1d18b63af8e6f7a696c20..ee3a3abf6e78e0ea7de150f0634ba568d5381460 100644 --- a/typo3/sysext/install/Classes/Controller/Action/Tool/AllConfiguration.php +++ b/typo3/sysext/install/Classes/Controller/Action/Tool/AllConfiguration.php @@ -90,7 +90,7 @@ class AllConfiguration extends Action\AbstractAction { } elseif (preg_match('/^(<.*?>)?boolean/i', $description)) { $itemData['type'] = 'checkbox'; $itemData['value'] = $value ? '1' : '0'; - $itemData['checked'] = (boolean)$value; + $itemData['checked'] = (bool)$value; } else { $itemData['type'] = 'input'; $itemData['value'] = $value; diff --git a/typo3/sysext/install/Classes/Service/SessionService.php b/typo3/sysext/install/Classes/Service/SessionService.php index 54bdb6e87caa94b14de1dd2aa51e0ed8b3ecdfa6..90ddcc982e2cb263b29dc1b713118c34949bb761 100644 --- a/typo3/sysext/install/Classes/Service/SessionService.php +++ b/typo3/sysext/install/Classes/Service/SessionService.php @@ -353,7 +353,7 @@ class SessionService implements \TYPO3\CMS\Core\SingletonInterface { */ public function read($id) { $sessionFile = $this->getSessionFile($id); - return (string) (@file_get_contents($sessionFile)); + return (string)(@file_get_contents($sessionFile)); } /** diff --git a/typo3/sysext/lang/Classes/Domain/Model/Extension.php b/typo3/sysext/lang/Classes/Domain/Model/Extension.php index b4f779c100cfd6948b890776eafaf2c53ebb5be6..34f73fe166307a9360d40ebe71de71d6580af59d 100644 --- a/typo3/sysext/lang/Classes/Domain/Model/Extension.php +++ b/typo3/sysext/lang/Classes/Domain/Model/Extension.php @@ -168,7 +168,7 @@ class Extension extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity { * @return void */ public function setUpdateResult($updateResult) { - $this->updateResult = (array) $updateResult; + $this->updateResult = (array)$updateResult; } /** diff --git a/typo3/sysext/lang/Classes/Domain/Repository/LanguageRepository.php b/typo3/sysext/lang/Classes/Domain/Repository/LanguageRepository.php index 0fc8ef782c46b9108c9c4d5fd56acacd54d2a9a1..7dee09c0be059217945eaa2ce698325942f6ac82 100644 --- a/typo3/sysext/lang/Classes/Domain/Repository/LanguageRepository.php +++ b/typo3/sysext/lang/Classes/Domain/Repository/LanguageRepository.php @@ -51,7 +51,7 @@ class LanguageRepository { public function __construct() { try { $globalSettings = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Core\\Configuration\\ConfigurationManager')->getLocalConfigurationValueByPath($this->configurationPath); - $this->selectedLanguages = (array) $globalSettings['availableLanguages']; + $this->selectedLanguages = (array)$globalSettings['availableLanguages']; } catch (\Exception $e) { \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Core\\Configuration\\ConfigurationManager')->setLocalConfigurationValueByPath( $this->configurationPath, diff --git a/typo3/sysext/lang/Classes/LanguageService.php b/typo3/sysext/lang/Classes/LanguageService.php index 6f879397efcca706efbbbbb6decc1882cc9ef777..9b3e9c05aa364e6a0269e362df53e845087a1883 100644 --- a/typo3/sysext/lang/Classes/LanguageService.php +++ b/typo3/sysext/lang/Classes/LanguageService.php @@ -406,7 +406,7 @@ class LanguageService { } // Localized addition? $lFileRef = $this->localizedFileRef($fileRef); - if ($lFileRef && (string) $globalLanguage[$this->lang] === 'EXT') { + if ($lFileRef && (string)$globalLanguage[$this->lang] === 'EXT') { $localLanguage = $this->readLLfile($lFileRef); ArrayUtility::mergeRecursiveWithOverrule($globalLanguage, $localLanguage); } diff --git a/typo3/sysext/lang/Classes/Service/UpdateTranslationService.php b/typo3/sysext/lang/Classes/Service/UpdateTranslationService.php index cf93a231508a480613df0661fade0753ebf56fe9..ff769c4c9c9086224f040fbd9a693bdc3262db60 100644 --- a/typo3/sysext/lang/Classes/Service/UpdateTranslationService.php +++ b/typo3/sysext/lang/Classes/Service/UpdateTranslationService.php @@ -69,7 +69,7 @@ class UpdateTranslationService { if (is_string($locales)) { $locales = \TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(',', $locales); } - $locales = array_flip((array) $locales); + $locales = array_flip((array)$locales); foreach ($locales as $locale => $key) { $state = static::TRANSLATION_INVALID; diff --git a/typo3/sysext/linkvalidator/Classes/Report/LinkValidatorReport.php b/typo3/sysext/linkvalidator/Classes/Report/LinkValidatorReport.php index 9d5e48b9f843cd400205263b913b27d97d00aa9c..f2c387cd91e71fa647578f8aedc917dada566207 100644 --- a/typo3/sysext/linkvalidator/Classes/Report/LinkValidatorReport.php +++ b/typo3/sysext/linkvalidator/Classes/Report/LinkValidatorReport.php @@ -702,7 +702,7 @@ class LinkValidatorReport extends \TYPO3\CMS\Backend\Module\AbstractFunctionModu * @return bool Whether the current user is admin */ protected function isCurrentUserAdmin() { - return (bool) $GLOBALS['BE_USER']->user['admin']; + return (bool)$GLOBALS['BE_USER']->user['admin']; } } diff --git a/typo3/sysext/lowlevel/Classes/AdminCommand.php b/typo3/sysext/lowlevel/Classes/AdminCommand.php index 392fe2fa3076ea233d1ae298b21a6a68e33d4232..7784b3be99470dc8ef7e361bc697bd2e13f6001c 100644 --- a/typo3/sysext/lowlevel/Classes/AdminCommand.php +++ b/typo3/sysext/lowlevel/Classes/AdminCommand.php @@ -65,14 +65,14 @@ class AdminCommand extends \TYPO3\CMS\Core\Controller\CommandLineController { $GLOBALS['BE_USER']->user['admin'] = 1; $GLOBALS['BE_USER']->setWorkspace(0); // Print help - $analysisType = (string) $this->cli_args['_DEFAULT'][1]; + $analysisType = (string)$this->cli_args['_DEFAULT'][1]; if (!$analysisType) { $this->cli_validateArgs(); $this->cli_help(); die; } // Analysis type: - switch ((string) $analysisType) { + switch ((string)$analysisType) { case 'setBElock': if (@is_file((PATH_typo3conf . 'LOCK_BACKEND'))) { $this->cli_echo('A lockfile already exists. Overwriting it... diff --git a/typo3/sysext/lowlevel/Classes/CleanerCommand.php b/typo3/sysext/lowlevel/Classes/CleanerCommand.php index 9301078fff9f689f8008498f35630bc6e2563d80..4264bb5fccb870895d49c1557e33fa1d570e2719 100644 --- a/typo3/sysext/lowlevel/Classes/CleanerCommand.php +++ b/typo3/sysext/lowlevel/Classes/CleanerCommand.php @@ -65,7 +65,7 @@ class CleanerCommand extends \TYPO3\CMS\Core\Controller\CommandLineController { public function __construct() { // Running parent class constructor parent::__construct(); - $this->cleanerModules = (array) $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['lowlevel']['cleanerModules']; + $this->cleanerModules = (array)$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['lowlevel']['cleanerModules']; // Adding options to help archive: $this->cli_options[] = array('-r', 'Execute this tool, otherwise help is shown'); $this->cli_options[] = array('-v level', 'Verbosity level 0-3', 'The value of level can be: @@ -117,7 +117,7 @@ This will show you missing files in the TYPO3 system and only report back if err die; } // Print help - $analysisType = (string) $this->cli_args['_DEFAULT'][1]; + $analysisType = (string)$this->cli_args['_DEFAULT'][1]; if (!$analysisType) { $this->cli_validateArgs(); $this->cli_help(); diff --git a/typo3/sysext/lowlevel/Classes/MissingFilesCommand.php b/typo3/sysext/lowlevel/Classes/MissingFilesCommand.php index 8773f69b7aed21fd754a8ca436e0083e91d24573..872d959e98207a6e72138da36bd31218f0a1510c 100644 --- a/typo3/sysext/lowlevel/Classes/MissingFilesCommand.php +++ b/typo3/sysext/lowlevel/Classes/MissingFilesCommand.php @@ -83,7 +83,7 @@ This will show you missing files in the TYPO3 system and only report back if err $infoString = $this->infoStr($rec); // Handle missing file: if (!@is_file((PATH_site . $rec['ref_string']))) { - if ((string) $rec['softref_key'] == '') { + if ((string)$rec['softref_key'] == '') { $resultArrayIndex = 'managedFilesMissing'; } else { $resultArrayIndex = 'softrefFilesMissing'; diff --git a/typo3/sysext/recordlist/Classes/Browser/ElementBrowser.php b/typo3/sysext/recordlist/Classes/Browser/ElementBrowser.php index 34788ad9ad735a0d3cab31a4d0c2d55086d6ad89..c89f14933039f0765504dc2dcfa99c8ef862d52d 100644 --- a/typo3/sysext/recordlist/Classes/Browser/ElementBrowser.php +++ b/typo3/sysext/recordlist/Classes/Browser/ElementBrowser.php @@ -330,7 +330,7 @@ class ElementBrowser { */ public function initConfiguration() { // Rich Text Editor specific configuration: - if ((string) $this->mode === 'rte') { + if ((string)$this->mode === 'rte') { $this->thisConfig = $this->getRTEConfig(); } } @@ -796,7 +796,7 @@ class ElementBrowser { */ public function processSessionData($data) { $store = FALSE; - switch ((string) $this->mode) { + switch ((string)$this->mode) { case 'db': if (isset($this->expandPage)) { $data['expandPage'] = $this->expandPage; diff --git a/typo3/sysext/recordlist/Classes/Controller/ElementBrowserController.php b/typo3/sysext/recordlist/Classes/Controller/ElementBrowserController.php index e87f42c778748f32ff5a17b427aa2cbb98343fd9..002a6acbdfae3c5953466b60f8f41d94356f59e6 100644 --- a/typo3/sysext/recordlist/Classes/Controller/ElementBrowserController.php +++ b/typo3/sysext/recordlist/Classes/Controller/ElementBrowserController.php @@ -103,7 +103,7 @@ class ElementBrowserController { } $this->content = ''; // Look for alternative mountpoints - switch ((string) $this->mode) { + switch ((string)$this->mode) { case 'rte': case 'db': case 'wizard': @@ -136,7 +136,7 @@ class ElementBrowserController { list($modData, $store) = $this->browser->processSessionData($modData); $GLOBALS['BE_USER']->pushModuleData('browse_links.php', $modData); // Output the correct content according to $this->mode - switch ((string) $this->mode) { + switch ((string)$this->mode) { case 'rte': $this->content = $this->browser->main_rte(); break; diff --git a/typo3/sysext/recordlist/Classes/RecordList.php b/typo3/sysext/recordlist/Classes/RecordList.php index 128ed6eacae2e274e701f9f030f1e5b8dd1afd12..6347ede62fd237cb82cb964ceba9b588ae43fdc0 100644 --- a/typo3/sysext/recordlist/Classes/RecordList.php +++ b/typo3/sysext/recordlist/Classes/RecordList.php @@ -228,7 +228,7 @@ class RecordList { // CBH is all the fields selected for the clipboard, CBC is the checkbox fields which were checked. // By merging we get a full array of checked/unchecked elements // This is set to the 'el' array of the CB after being parsed so only the table in question is registered. - $CB['el'] = $dblist->clipObj->cleanUpCBC(array_merge((array) GeneralUtility::_POST('CBH'), (array) GeneralUtility::_POST('CBC')), $this->cmd_table); + $CB['el'] = $dblist->clipObj->cleanUpCBC(array_merge((array)GeneralUtility::_POST('CBH'), (array)GeneralUtility::_POST('CBC')), $this->cmd_table); } if (!$this->MOD_SETTINGS['clipBoard']) { // If the clipboard is NOT shown, set the pad to 'normal'. diff --git a/typo3/sysext/recordlist/Classes/RecordList/AbstractDatabaseRecordList.php b/typo3/sysext/recordlist/Classes/RecordList/AbstractDatabaseRecordList.php index a5231821f5d52eba5a1dc4e821f79700f7c4111a..8577f843208ca5cdac61e74d4052d435d5827d37 100644 --- a/typo3/sysext/recordlist/Classes/RecordList/AbstractDatabaseRecordList.php +++ b/typo3/sysext/recordlist/Classes/RecordList/AbstractDatabaseRecordList.php @@ -600,7 +600,7 @@ class AbstractDatabaseRecordList extends \TYPO3\CMS\Backend\RecordList\AbstractR $code = '<span title="' . htmlspecialchars($origCode, ENT_QUOTES, 'UTF-8', FALSE) . '">' . $code . '</span>'; } } - switch ((string) $this->clickTitleMode) { + switch ((string)$this->clickTitleMode) { case 'edit': // If the listed table is 'pages' we have to request the permission settings for each page: if ($table == 'pages') { diff --git a/typo3/sysext/recordlist/Classes/RecordList/DatabaseRecordList.php b/typo3/sysext/recordlist/Classes/RecordList/DatabaseRecordList.php index 5388dcd4287fa2ca1273d4a24bc76dbf241b9409..694e2fba2b10e6edadc38060567a5dc285d8e4b2 100644 --- a/typo3/sysext/recordlist/Classes/RecordList/DatabaseRecordList.php +++ b/typo3/sysext/recordlist/Classes/RecordList/DatabaseRecordList.php @@ -856,7 +856,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList { foreach ($this->fieldArray as $fCol) { // Calculate users permissions to edit records in the table: $permsEdit = $this->calcPerms & ($table == 'pages' ? 2 : 16); - switch ((string) $fCol) { + switch ((string)$fCol) { case '_PATH_': // Path $theData[$fCol] = '<i>[' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:labels._PATH_', TRUE) . ']</i>'; @@ -1435,7 +1435,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList { // For the "Normal" pad: if ($this->clipObj->current == 'normal') { // Show copy/cut icons: - $isSel = (string) $this->clipObj->isSelected($table, $row['uid']); + $isSel = (string)$this->clipObj->isSelected($table, $row['uid']); if ($isL10nOverlay) { $cells['copy'] = $this->spaceIcon; $cells['cut'] = $this->spaceIcon; diff --git a/typo3/sysext/recycler/Classes/Controller/RecyclerModuleController.php b/typo3/sysext/recycler/Classes/Controller/RecyclerModuleController.php index 6fd977f2d508bec75f3be610276ce7784eac7e33..49b62c063e290b5b5332a06b1255faeb2242007f 100644 --- a/typo3/sysext/recycler/Classes/Controller/RecyclerModuleController.php +++ b/typo3/sysext/recycler/Classes/Controller/RecyclerModuleController.php @@ -122,7 +122,7 @@ class RecyclerModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClass * @return bool Whether the current user is admin */ protected function isCurrentUserAdmin() { - return (bool) $GLOBALS['BE_USER']->user['admin']; + return (bool)$GLOBALS['BE_USER']->user['admin']; } /** @@ -203,7 +203,7 @@ class RecyclerModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClass */ protected function getJavaScriptLabelsFromLocallang($selectionPrefix = 'js.', $stripFromSelectionName = '') { $extraction = array(); - $labels = array_merge((array) $GLOBALS['LOCAL_LANG']['default'], (array) $GLOBALS['LOCAL_LANG'][$GLOBALS['LANG']->lang]); + $labels = array_merge((array)$GLOBALS['LOCAL_LANG']['default'], (array)$GLOBALS['LOCAL_LANG'][$GLOBALS['LANG']->lang]); // Regular expression to strip the selection prefix and possibly something from the label name: $labelPattern = '#^' . preg_quote($selectionPrefix, '#') . '(' . preg_quote($stripFromSelectionName, '#') . ')?#'; // Iterate through all locallang labels: diff --git a/typo3/sysext/reports/Classes/Report/Status/Typo3Status.php b/typo3/sysext/reports/Classes/Report/Status/Typo3Status.php index e886bdd7a1b44aa608fbc8be22864844cfeb500d..a344a44b7040610e673a20ecfd3e1e2b347497ae 100644 --- a/typo3/sysext/reports/Classes/Report/Status/Typo3Status.php +++ b/typo3/sysext/reports/Classes/Report/Status/Typo3Status.php @@ -55,8 +55,8 @@ class Typo3Status implements \TYPO3\CMS\Reports\StatusProviderInterface { $severity = \TYPO3\CMS\Reports\Status::OK; $xclasses = array_merge( - (array) $GLOBALS['TYPO3_CONF_VARS']['BE']['XCLASS'], - (array) $GLOBALS['TYPO3_CONF_VARS']['FE']['XCLASS'] + (array)$GLOBALS['TYPO3_CONF_VARS']['BE']['XCLASS'], + (array)$GLOBALS['TYPO3_CONF_VARS']['FE']['XCLASS'] ); $numberOfXclasses = count($xclasses); diff --git a/typo3/sysext/reports/Classes/Status.php b/typo3/sysext/reports/Classes/Status.php index 1fb3ef913e6a2eaa59aea06ab9b826309eb04bc1..6340e432b75024602057f58a316b90710851fd51 100644 --- a/typo3/sysext/reports/Classes/Status.php +++ b/typo3/sysext/reports/Classes/Status.php @@ -58,9 +58,9 @@ class Status { * @param int $severity A severity level. Use one of the constants above! */ public function __construct($title, $value, $message = '', $severity = self::OK) { - $this->title = (string) $title; - $this->value = (string) $value; - $this->message = (string) $message; + $this->title = (string)$title; + $this->value = (string)$value; + $this->message = (string)$message; $this->severity = \TYPO3\CMS\Core\Utility\MathUtility::forceIntegerInRange($severity, self::NOTICE, self::ERROR, self::OK); } diff --git a/typo3/sysext/rtehtmlarea/Classes/Extension/Language.php b/typo3/sysext/rtehtmlarea/Classes/Extension/Language.php index 037c434c826cf7be6026cb87b3b0139457b96d6e..333a7d41ba906fbf884d74bb8c1523bc220b8265 100644 --- a/typo3/sysext/rtehtmlarea/Classes/Extension/Language.php +++ b/typo3/sysext/rtehtmlarea/Classes/Extension/Language.php @@ -116,8 +116,8 @@ class Language extends \TYPO3\CMS\Rtehtmlarea\RteHtmlAreaApi { $where .= ' AND ' . $table . '.lg_iso_2 IN (' . $languageList . ')'; } $res = $GLOBALS['TYPO3_DB']->exec_SELECTquery($table . '.lg_iso_2,' . $table . '.lg_country_iso_2,' . $labelFields, $table, $where . ' AND lg_constructed = 0 ' . ($this->htmlAreaRTE->is_FE() ? $GLOBALS['TSFE']->sys_page->enableFields($table) : \TYPO3\CMS\Backend\Utility\BackendUtility::BEenableFields($table) . \TYPO3\CMS\Backend\Utility\BackendUtility::deleteClause($table))); - $prefixLabelWithCode = (boolean)$this->thisConfig['buttons.']['language.']['prefixLabelWithCode']; - $postfixLabelWithCode = (boolean)$this->thisConfig['buttons.']['language.']['postfixLabelWithCode']; + $prefixLabelWithCode = (bool)$this->thisConfig['buttons.']['language.']['prefixLabelWithCode']; + $postfixLabelWithCode = (bool)$this->thisConfig['buttons.']['language.']['postfixLabelWithCode']; while ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res)) { $code = strtolower($row['lg_iso_2']) . ($row['lg_country_iso_2'] ? '-' . strtoupper($row['lg_country_iso_2']) : ''); foreach ($titleFields as $titleField) { diff --git a/typo3/sysext/rtehtmlarea/Classes/SelectImage.php b/typo3/sysext/rtehtmlarea/Classes/SelectImage.php index 3ee4a4c428ffa66141afc2228654bfa20f056996..75f26c74675828b8692775f7cb75487caea60715 100644 --- a/typo3/sysext/rtehtmlarea/Classes/SelectImage.php +++ b/typo3/sysext/rtehtmlarea/Classes/SelectImage.php @@ -155,7 +155,7 @@ class SelectImage extends \TYPO3\CMS\Recordlist\Browser\ElementBrowser { */ protected function insertImage() { $table = htmlspecialchars(GeneralUtility::_GP('table')); - $uid = (int) GeneralUtility::_GP('uid'); + $uid = (int)GeneralUtility::_GP('uid'); if (GeneralUtility::_GP('insertImage') && $uid) { /** @var $fileObject Resource\File */ $fileObject = Resource\ResourceFactory::getInstance()->getFileObject($uid); diff --git a/typo3/sysext/rtehtmlarea/Classes/User.php b/typo3/sysext/rtehtmlarea/Classes/User.php index f7c5aa2f93969617c7638c77bf36e061e8d40321..ba6fe0d086d6ed9856d6bdc8010aa1a28a2a8efd 100644 --- a/typo3/sysext/rtehtmlarea/Classes/User.php +++ b/typo3/sysext/rtehtmlarea/Classes/User.php @@ -196,7 +196,7 @@ class User { foreach ($files as $filename) { $iInfo = @getimagesize((PATH_site . $v['path'] . $filename)); $iInfo = $this->calcWH($iInfo, 50, 100); - $ks = (string) (100 + $c); + $ks = (string)(100 + $c); $mArray[$ks] = $filename; $mArray[$ks . '.'] = array( 'content' => '<img src="' . $this->siteUrl . $v['path'] . $filename . '" />', @@ -231,7 +231,7 @@ class User { } $logo = $v[$k2i . '.']['_icon'] ?: ''; $onClickEvent = ''; - switch ((string) $v[($k2i . '.')]['mode']) { + switch ((string)$v[($k2i . '.')]['mode']) { case 'wrap': $wrap = explode('|', $v[$k2i . '.']['content']); $onClickEvent = 'wrapHTML(' . GeneralUtility::quoteJSvalue($wrap[0]) . ',' . GeneralUtility::quoteJSvalue($wrap[1]) . ',false);'; diff --git a/typo3/sysext/saltedpasswords/Classes/Task/BulkUpdateFieldProvider.php b/typo3/sysext/saltedpasswords/Classes/Task/BulkUpdateFieldProvider.php index 4bf7c5c024b77548548926bc286b4392c19fa6ca..6e4ae910f8780c3273b177f017909d0203b3f82c 100644 --- a/typo3/sysext/saltedpasswords/Classes/Task/BulkUpdateFieldProvider.php +++ b/typo3/sysext/saltedpasswords/Classes/Task/BulkUpdateFieldProvider.php @@ -61,7 +61,7 @@ class BulkUpdateFieldProvider implements \TYPO3\CMS\Scheduler\AdditionalFieldPro $fieldName = 'tx_scheduler[scheduler_saltedpasswordsBulkUpdateCanDeactivateSelf]'; $fieldId = 'task_saltedpasswordsBulkUpdateCanDeactivateSelf'; $fieldValue = 'IsChecked'; - $fieldChecked = (bool) $taskInfo['scheduler_saltedpasswordsBulkUpdateCanDeactivateSelf']; + $fieldChecked = (bool)$taskInfo['scheduler_saltedpasswordsBulkUpdateCanDeactivateSelf']; $fieldHtml = '<input type="checkbox"' . ' name="' . $fieldName . '"' . ' id="' . $fieldId . '"' . ' value="' . $fieldValue . '"' . ($fieldChecked ? ' checked="checked"' : '') . ' />'; $additionalFields[$fieldId] = array( 'code' => $fieldHtml, diff --git a/typo3/sysext/saltedpasswords/Classes/Task/BulkUpdateTask.php b/typo3/sysext/saltedpasswords/Classes/Task/BulkUpdateTask.php index 22dfdbc83986f921f1bd7e779ef8c0cfb0902319..472776dc5ff297d09828d6d4bc27f15ab8c4e3f9 100644 --- a/typo3/sysext/saltedpasswords/Classes/Task/BulkUpdateTask.php +++ b/typo3/sysext/saltedpasswords/Classes/Task/BulkUpdateTask.php @@ -188,7 +188,7 @@ class BulkUpdateTask extends \TYPO3\CMS\Scheduler\Task\AbstractTask { * @return bool TRUE if password is md5 */ protected function isMd5Password($password) { - return (bool) preg_match('/[0-9abcdef]{32,32}/i', $password); + return (bool)preg_match('/[0-9abcdef]{32,32}/i', $password); } /** diff --git a/typo3/sysext/saltedpasswords/Classes/Utility/ExtensionManagerConfigurationUtility.php b/typo3/sysext/saltedpasswords/Classes/Utility/ExtensionManagerConfigurationUtility.php index 807c454e4b9f975a3047cc6f99923f1c441690a6..53452646ef63c2c2750fd2d5a314af79054a42fa 100644 --- a/typo3/sysext/saltedpasswords/Classes/Utility/ExtensionManagerConfigurationUtility.php +++ b/typo3/sysext/saltedpasswords/Classes/Utility/ExtensionManagerConfigurationUtility.php @@ -120,10 +120,10 @@ your TYPO3 installation and the usability of the backend.'; * @return void */ private function init() { - $requestSetup = $this->processPostData((array) $_REQUEST['data']); + $requestSetup = $this->processPostData((array)$_REQUEST['data']); $extConf = unserialize($GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf']['saltedpasswords']); - $this->extConf['BE'] = array_merge((array) $extConf['BE.'], (array) $requestSetup['BE.']); - $this->extConf['FE'] = array_merge((array) $extConf['FE.'], (array) $requestSetup['FE.']); + $this->extConf['BE'] = array_merge((array)$extConf['BE.'], (array)$requestSetup['BE.']); + $this->extConf['FE'] = array_merge((array)$extConf['FE.'], (array)$requestSetup['FE.']); $GLOBALS['LANG']->includeLLFile('EXT:saltedpasswords/locallang.xlf'); } @@ -402,7 +402,7 @@ Please disable either one of them.'; if (count($parts) == 2) { // TODO: Explain $value = $this->processPostData(array($parts[1] => $value)); - $postArray[$parts[0] . '.'] = array_merge((array) $postArray[($parts[0] . '.')], $value); + $postArray[$parts[0] . '.'] = array_merge((array)$postArray[($parts[0] . '.')], $value); } else { // TODO: Explain $postArray[$parts[0]] = $value; diff --git a/typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php b/typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php index a3f4feec120b0466b4fac9cb2b546774583a041c..385d3070c8c624ef49348e275eceb372c1747fbb 100644 --- a/typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php +++ b/typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php @@ -179,7 +179,7 @@ class SchedulerModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClas } } // Handle chosen action - switch ((string) $this->MOD_SETTINGS['function']) { + switch ((string)$this->MOD_SETTINGS['function']) { case 'scheduler': // Scheduler's main screen $this->executeTasks(); diff --git a/typo3/sysext/scheduler/Classes/CronCommand/CronCommand.php b/typo3/sysext/scheduler/Classes/CronCommand/CronCommand.php index f58e84d0b232fb5d82294fbd9b38790845e3ece2..710c28b9c550f4e1b650edd791046c13a00eb845 100644 --- a/typo3/sysext/scheduler/Classes/CronCommand/CronCommand.php +++ b/typo3/sysext/scheduler/Classes/CronCommand/CronCommand.php @@ -184,7 +184,7 @@ class CronCommand { */ protected function isInCommandList($commandExpression, $numberToMatch) { $inList = FALSE; - if ((string) $commandExpression === '*') { + if ((string)$commandExpression === '*') { $inList = TRUE; } else { $inList = \TYPO3\CMS\Core\Utility\GeneralUtility::inList($commandExpression, $numberToMatch); diff --git a/typo3/sysext/scheduler/Classes/CronCommand/NormalizeCommand.php b/typo3/sysext/scheduler/Classes/CronCommand/NormalizeCommand.php index f4a25d1ab6d119519ac7704beb728c0877006afa..a7aea073757e19205c8b591f3acdfed540602de8 100644 --- a/typo3/sysext/scheduler/Classes/CronCommand/NormalizeCommand.php +++ b/typo3/sysext/scheduler/Classes/CronCommand/NormalizeCommand.php @@ -117,7 +117,7 @@ class NormalizeCommand { * @return string Normalized expression */ static protected function normalizeMonthAndWeekdayField($expression, $isMonthField = TRUE) { - if ((string) $expression === '*') { + if ((string)$expression === '*') { $fieldValues = '*'; } else { // Fragment expression by , / and - and substitute three letter code of month and weekday to numbers @@ -132,7 +132,7 @@ class NormalizeCommand { $rightBound = self::normalizeMonthAndWeekday($rightBound, $isMonthField); $left = $leftBound . '-' . $rightBound; } else { - if ((string) $left !== '*') { + if ((string)$left !== '*') { $left = self::normalizeMonthAndWeekday($left, $isMonthField); } } @@ -161,7 +161,7 @@ class NormalizeCommand { * @return string Normalized expression */ static protected function normalizeIntegerField($expression, $lowerBound = 0, $upperBound = 59) { - if ((string) $expression === '*') { + if ((string)$expression === '*') { $fieldValues = '*'; } else { $listOfCommaValues = explode(',', $expression); @@ -169,7 +169,7 @@ class NormalizeCommand { foreach ($listOfCommaValues as $listElement) { if (strpos($listElement, '/') !== FALSE) { list($left, $right) = explode('/', $listElement); - if ((string) $left === '*') { + if ((string)$left === '*') { $leftList = self::convertRangeToListOfValues($lowerBound . '-' . $upperBound); } else { $leftList = self::convertRangeToListOfValues($left); @@ -188,7 +188,7 @@ class NormalizeCommand { if (strlen($fieldValues) === 0) { throw new \InvalidArgumentException('Unable to convert integer field to list of values: Result list empty.', 1291422012); } - if ((string) $fieldValues !== '*') { + if ((string)$fieldValues !== '*') { $fieldList = explode(',', $fieldValues); sort($fieldList); $fieldList = array_unique($fieldList); @@ -200,7 +200,7 @@ class NormalizeCommand { } $fieldValues = implode(',', $fieldList); } - return (string) $fieldValues; + return (string)$fieldValues; } /** @@ -239,7 +239,7 @@ class NormalizeCommand { } else { throw new \InvalidArgumentException('Unable to convert range to list of values.', 1291234986); } - return (string) $resultList; + return (string)$resultList; } /** @@ -302,7 +302,7 @@ class NormalizeCommand { */ static protected function normalizeMonthAndWeekday($expression, $isMonth = TRUE) { $expression = $isMonth ? self::normalizeMonth($expression) : self::normalizeWeekday($expression); - return (string) $expression; + return (string)$expression; } /** @@ -333,7 +333,7 @@ class NormalizeCommand { static protected function normalizeWeekday($weekday) { $normalizedWeekday = FALSE; // 0 (sunday) -> 7 - if ((string) $weekday === '0') { + if ((string)$weekday === '0') { $weekday = 7; } if ($weekday >= 1 && $weekday <= 7) { diff --git a/typo3/sysext/setup/Classes/Controller/SetupModuleController.php b/typo3/sysext/setup/Classes/Controller/SetupModuleController.php index 26519fb121217208bcb5f2215ef1f7a4676cc1a3..66bd4435f6c6ece4e38348bcd6e9f9f5d1aff6f5 100644 --- a/typo3/sysext/setup/Classes/Controller/SetupModuleController.php +++ b/typo3/sysext/setup/Classes/Controller/SetupModuleController.php @@ -163,7 +163,7 @@ class SetupModuleController { $beUserId = $GLOBALS['BE_USER']->user['uid']; $storeRec = array(); $fieldList = $this->getFieldsFromShowItem(); - if (is_array($d) && $this->formProtection->validateToken((string) GeneralUtility::_POST('formToken'), 'BE user setup', 'edit')) { + if (is_array($d) && $this->formProtection->validateToken((string)GeneralUtility::_POST('formToken'), 'BE user setup', 'edit')) { // UC hashed before applying changes $save_before = md5(serialize($GLOBALS['BE_USER']->uc)); // PUT SETTINGS into the ->uc array: diff --git a/typo3/sysext/sv/Classes/AuthenticationService.php b/typo3/sysext/sv/Classes/AuthenticationService.php index e25bce3d8fc27d59e1a228b628727ea95b0be8af..7feec8e64e7a91e5fc7e4fcc1d77adfc4b61f124 100644 --- a/typo3/sysext/sv/Classes/AuthenticationService.php +++ b/typo3/sysext/sv/Classes/AuthenticationService.php @@ -50,8 +50,8 @@ class AuthenticationService extends \TYPO3\CMS\Sv\AbstractAuthenticationService $isProcessed = FALSE; } if (!empty($loginData['uident_text'])) { - $loginData['uident_challenged'] = (string) md5(($loginData['uname'] . ':' . $loginData['uident_text'] . ':' . $loginData['chalvalue'])); - $loginData['uident_superchallenged'] = (string) md5(($loginData['uname'] . ':' . md5($loginData['uident_text']) . ':' . $loginData['chalvalue'])); + $loginData['uident_challenged'] = (string)md5(($loginData['uname'] . ':' . $loginData['uident_text'] . ':' . $loginData['chalvalue'])); + $loginData['uident_superchallenged'] = (string)md5(($loginData['uname'] . ':' . md5($loginData['uident_text']) . ':' . $loginData['chalvalue'])); $isProcessed = TRUE; } return $isProcessed; diff --git a/typo3/sysext/sys_note/Classes/Domain/Repository/SysNoteRepository.php b/typo3/sysext/sys_note/Classes/Domain/Repository/SysNoteRepository.php index f35999f411b7aed0813e494b9acae53574d5993b..c37fdfe69bf722c2f69ec79be85bc18158924acc 100644 --- a/typo3/sysext/sys_note/Classes/Domain/Repository/SysNoteRepository.php +++ b/typo3/sysext/sys_note/Classes/Domain/Repository/SysNoteRepository.php @@ -41,7 +41,7 @@ class SysNoteRepository extends \TYPO3\CMS\Extbase\Persistence\Repository { * @return \TYPO3\CMS\Extbase\Persistence\QueryResultInterface */ public function findByPidsAndAuthor($pids, \TYPO3\CMS\Extbase\Domain\Model\BackendUser $author) { - $pids = \TYPO3\CMS\Core\Utility\GeneralUtility::intExplode(',', (string) $pids); + $pids = \TYPO3\CMS\Core\Utility\GeneralUtility::intExplode(',', (string)$pids); $query = $this->createQuery(); $query->setOrderings(array( 'sorting' => \TYPO3\CMS\Extbase\Persistence\QueryInterface::ORDER_ASCENDING, diff --git a/typo3/sysext/t3editor/Classes/T3editor.php b/typo3/sysext/t3editor/Classes/T3editor.php index e9ec03b244951543cace4163b6e35efe6e6a9e95..70bad5fbad253156df10cad884029688ffa36841 100644 --- a/typo3/sysext/t3editor/Classes/T3editor.php +++ b/typo3/sysext/t3editor/Classes/T3editor.php @@ -323,7 +323,7 @@ class T3editor implements \TYPO3\CMS\Core\SingletonInterface { */ protected function getJavaScriptLabelsFromLocallang($selectionPrefix = 'js.', $stripFromSelectionName = '') { $extraction = array(); - $labels = array_merge((array) $GLOBALS['LOCAL_LANG']['default'], (array) $GLOBALS['LOCAL_LANG'][$GLOBALS['LANG']->lang]); + $labels = array_merge((array)$GLOBALS['LOCAL_LANG']['default'], (array)$GLOBALS['LOCAL_LANG'][$GLOBALS['LANG']->lang]); // Regular expression to strip the selection prefix and possibly something from the label name: $labelPattern = '#^' . preg_quote($selectionPrefix, '#') . '(' . preg_quote($stripFromSelectionName, '#') . ')?#'; // Iterate throuh all locallang lables: diff --git a/typo3/sysext/taskcenter/Classes/Controller/TaskModuleController.php b/typo3/sysext/taskcenter/Classes/Controller/TaskModuleController.php index 6012f9119eece7ba7e2faf1e6a150199963c2ac9..366b0f7dd89733cfc41bbb076a56e752aeb92f68 100644 --- a/typo3/sysext/taskcenter/Classes/Controller/TaskModuleController.php +++ b/typo3/sysext/taskcenter/Classes/Controller/TaskModuleController.php @@ -67,7 +67,7 @@ class TaskModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClass { $this->doc->postCode = $this->doc->wrapScriptTags('if (top.fsMod) { top.fsMod.recentIds["web"] = 0; }'); // Render content depending on the mode - $mode = (string) $this->MOD_SETTINGS['mode']; + $mode = (string)$this->MOD_SETTINGS['mode']; if ($mode == 'information') { $this->renderInformationContent(); } else { @@ -98,7 +98,7 @@ class TaskModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClass { */ protected function renderModuleContent() { $title = ($content = ($actionContent = '')); - $chosenTask = (string) $this->MOD_SETTINGS['function']; + $chosenTask = (string)$this->MOD_SETTINGS['function']; // Render the taskcenter task as default if (empty($chosenTask) || $chosenTask == 'index') { $chosenTask = 'taskcenter.tasks'; @@ -231,7 +231,7 @@ class TaskModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClass { $additionalClass .= ' last-item'; } // Active menu item - $active = (string) $this->MOD_SETTINGS['function'] == $item['uid'] ? ' active-task' : ''; + $active = (string)$this->MOD_SETTINGS['function'] == $item['uid'] ? ' active-task' : ''; // Main menu: Render additional syntax to sort tasks if ($mainMenu) { $dragIcon = '<img' . \TYPO3\CMS\Backend\Utility\IconUtility::skinImg($GLOBALS['BACK_PATH'], 'gfx/move.gif', 'width="16" height="16" hspace="2"') . ' title="' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_core.xlf:labels.move', TRUE) . '" alt="" />'; diff --git a/typo3/sysext/taskcenter/Classes/TaskStatus.php b/typo3/sysext/taskcenter/Classes/TaskStatus.php index e2a31c8d6ca8f2314620a7e048a6b54f48e1576e..2eecc525d753b5459b6c03c7b2ad984c375cb174 100644 --- a/typo3/sysext/taskcenter/Classes/TaskStatus.php +++ b/typo3/sysext/taskcenter/Classes/TaskStatus.php @@ -31,7 +31,7 @@ class TaskStatus { public function saveCollapseState(array $params, \TYPO3\CMS\Core\Http\AjaxRequestHandler $ajaxObj) { // Remove 'el_' in the beginning which is needed for the saveSortingState() $item = substr(htmlspecialchars(\TYPO3\CMS\Core\Utility\GeneralUtility::_POST('item')), 3); - $state = (bool) \TYPO3\CMS\Core\Utility\GeneralUtility::_POST('state'); + $state = (bool)\TYPO3\CMS\Core\Utility\GeneralUtility::_POST('state'); $GLOBALS['BE_USER']->uc['taskcenter']['states'][$item] = $state; $GLOBALS['BE_USER']->writeUC(); } diff --git a/typo3/sysext/version/Classes/DataHandler/CommandMap.php b/typo3/sysext/version/Classes/DataHandler/CommandMap.php index c04f90da1c33097fc576436126027ccf9dde9cd0..6e85b19ae400ab1aa858794fed44a2cec1ef3406 100644 --- a/typo3/sysext/version/Classes/DataHandler/CommandMap.php +++ b/typo3/sysext/version/Classes/DataHandler/CommandMap.php @@ -188,7 +188,7 @@ class CommandMap { * @return \TYPO3\CMS\Version\DataHandler\CommandMap */ public function setWorkspacesSwapMode($workspacesSwapMode) { - $this->workspacesSwapMode = (string) $workspacesSwapMode; + $this->workspacesSwapMode = (string)$workspacesSwapMode; return $this; } @@ -200,7 +200,7 @@ class CommandMap { * @return \TYPO3\CMS\Version\DataHandler\CommandMap */ public function setWorkspacesChangeStageMode($workspacesChangeStageMode) { - $this->workspacesChangeStageMode = (string) $workspacesChangeStageMode; + $this->workspacesChangeStageMode = (string)$workspacesChangeStageMode; return $this; } @@ -212,7 +212,7 @@ class CommandMap { * @return \TYPO3\CMS\Version\DataHandler\CommandMap */ public function setWorkspacesConsiderReferences($workspacesConsiderReferences) { - $this->workspacesConsiderReferences = (bool) $workspacesConsiderReferences; + $this->workspacesConsiderReferences = (bool)$workspacesConsiderReferences; return $this; } diff --git a/typo3/sysext/version/Classes/Dependency/DependencyResolver.php b/typo3/sysext/version/Classes/Dependency/DependencyResolver.php index 5c4f4bde7839d9657f6389302f608409b5fa7125..90a0e5d2e8771bbee2a7a84e6afd4b8a03766154 100644 --- a/typo3/sysext/version/Classes/Dependency/DependencyResolver.php +++ b/typo3/sysext/version/Classes/Dependency/DependencyResolver.php @@ -55,7 +55,7 @@ class DependencyResolver { * @param int $workspace */ public function setWorkspace($workspace) { - $this->workspace = (int) $workspace; + $this->workspace = (int)$workspace; } /** @@ -103,7 +103,7 @@ class DependencyResolver { * @return \TYPO3\CMS\Version\Dependency\DependencyResolver */ public function setOuterMostParentsRequireReferences($outerMostParentsRequireReferences) { - $this->outerMostParentsRequireReferences = (bool) $outerMostParentsRequireReferences; + $this->outerMostParentsRequireReferences = (bool)$outerMostParentsRequireReferences; return $this; } diff --git a/typo3/sysext/version/Classes/Hook/DataHandlerHook.php b/typo3/sysext/version/Classes/Hook/DataHandlerHook.php index 4427bf4eb994fc095b81bce750546a8bd3cc10e3..ae74ae8fe7c0476e06b7dd4a37c6256167a8fc4e 100644 --- a/typo3/sysext/version/Classes/Hook/DataHandlerHook.php +++ b/typo3/sysext/version/Classes/Hook/DataHandlerHook.php @@ -79,7 +79,7 @@ class DataHandlerHook { // custom command "version" if ($command == 'version') { $commandIsProcessed = TRUE; - $action = (string) $value['action']; + $action = (string)$value['action']; $comment = (isset($value['comment']) && $value['comment'] ? $value['comment'] : $this->generalComment); $notificationAlternativeRecipients = (isset($value['notificationAlternativeRecipients'])) && is_array($value['notificationAlternativeRecipients']) ? $value['notificationAlternativeRecipients'] : array(); switch ($action) { diff --git a/typo3/sysext/viewpage/Classes/Controller/ViewModuleController.php b/typo3/sysext/viewpage/Classes/Controller/ViewModuleController.php index 84fd81a24d35dc0bbd709b779b5a3f54d9bdd3a3..103273ac03408cba1f748922adf31638fe02d10f 100644 --- a/typo3/sysext/viewpage/Classes/Controller/ViewModuleController.php +++ b/typo3/sysext/viewpage/Classes/Controller/ViewModuleController.php @@ -74,7 +74,7 @@ class ViewModuleController extends \TYPO3\CMS\Extbase\Mvc\Controller\ActionContr $protocolAndHost = '..'; if ($domainName) { $protocol = 'http'; - $page = (array) $sysPage->getPage($finalPageIdToShow); + $page = (array)$sysPage->getPage($finalPageIdToShow); if ($page['url_scheme'] == 2 || $page['url_scheme'] == 0 && \TYPO3\CMS\Core\Utility\GeneralUtility::getIndpEnv('TYPO3_SSL')) { $protocol = 'https'; } diff --git a/typo3/sysext/workspaces/Classes/ExtDirect/AbstractHandler.php b/typo3/sysext/workspaces/Classes/ExtDirect/AbstractHandler.php index 976217e7ec394c2675f43f8a522a9cebac719f4c..88d2b758beea71b08a828c440159129802831de5 100644 --- a/typo3/sysext/workspaces/Classes/ExtDirect/AbstractHandler.php +++ b/typo3/sysext/workspaces/Classes/ExtDirect/AbstractHandler.php @@ -85,7 +85,7 @@ abstract class AbstractHandler { protected function getAffectedElements(\stdClass $parameters) { $affectedElements = array(); if ($parameters->type === 'selection') { - foreach ((array) $parameters->selection as $element) { + foreach ((array)$parameters->selection as $element) { $affectedElements[] = \TYPO3\CMS\Workspaces\Domain\Model\CombinedRecord::create($element->table, $element->liveId, $element->versionId); } } elseif ($parameters->type === 'all') { diff --git a/typo3/sysext/workspaces/Classes/Service/WorkspaceService.php b/typo3/sysext/workspaces/Classes/Service/WorkspaceService.php index 5f213363d10676685534254b86aa114f189b80d1..51f24ea128f5e7d6e75da11e04c726cf9d27176e 100644 --- a/typo3/sysext/workspaces/Classes/Service/WorkspaceService.php +++ b/typo3/sysext/workspaces/Classes/Service/WorkspaceService.php @@ -42,7 +42,7 @@ class WorkspaceService implements \TYPO3\CMS\Core\SingletonInterface { public function getAvailableWorkspaces() { $availableWorkspaces = array(); // add default workspaces - if ($GLOBALS['BE_USER']->checkWorkspace(array('uid' => (string) self::LIVE_WORKSPACE_ID))) { + if ($GLOBALS['BE_USER']->checkWorkspace(array('uid' => (string)self::LIVE_WORKSPACE_ID))) { $availableWorkspaces[self::LIVE_WORKSPACE_ID] = self::getWorkspaceTitle(self::LIVE_WORKSPACE_ID); } // add custom workspaces (selecting all, filtering by BE_USER check):