Completed
Pull Request — master (#248)
by Pascale
03:32
created
Classes/Service/TcaService.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -140,8 +140,8 @@
 block discarded – undo
140 140
     {
141 141
         $title = '';
142 142
         if ($row['start_date']) {
143
-            $dateStart = \strftime(DateTimeUtility::FORMAT_DATE_BACKEND, (int) $row['start_date']);
144
-            $dateEnd = \strftime(DateTimeUtility::FORMAT_DATE_BACKEND, (int) ($row['end_date'] ?: $row['start_date']));
143
+            $dateStart = \strftime(DateTimeUtility::FORMAT_DATE_BACKEND, (int)$row['start_date']);
144
+            $dateEnd = \strftime(DateTimeUtility::FORMAT_DATE_BACKEND, (int)($row['end_date'] ?: $row['start_date']));
145 145
             $title .= $dateStart;
146 146
             if ($dateStart !== $dateEnd) {
147 147
                 $title .= ' - ' . $dateEnd;
Please login to merge, or discard this patch.
Classes/Service/IndexPreparationService.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -82,11 +82,11 @@  discard block
 block discarded – undo
82 82
         if (!$languageField || !$transPointer) {
83 83
             return;
84 84
         }
85
-        if ((int) $record[$transPointer] > 0) {
85
+        if ((int)$record[$transPointer] > 0) {
86 86
             // no Index for language child elements
87 87
             return;
88 88
         }
89
-        $language = (int) $record[$languageField];
89
+        $language = (int)$record[$languageField];
90 90
 
91 91
         foreach (\array_keys($neededItems) as $key) {
92 92
             $neededItems[$key]['sys_language_uid'] = $language;
@@ -109,16 +109,16 @@  discard block
 block discarded – undo
109 109
 
110 110
         $addFields = [];
111 111
         if (isset($enableFields['disabled'])) {
112
-            $addFields['hidden'] = (int) $record[$enableFields['disabled']];
112
+            $addFields['hidden'] = (int)$record[$enableFields['disabled']];
113 113
         }
114 114
         if (isset($enableFields['starttime'])) {
115
-            $addFields['starttime'] = (int) $record[$enableFields['starttime']];
115
+            $addFields['starttime'] = (int)$record[$enableFields['starttime']];
116 116
         }
117 117
         if (isset($enableFields['endtime'])) {
118
-            $addFields['endtime'] = (int) $record[$enableFields['endtime']];
118
+            $addFields['endtime'] = (int)$record[$enableFields['endtime']];
119 119
         }
120 120
         if (isset($enableFields['fe_group'])) {
121
-            $addFields['fe_group'] = (string) $record[$enableFields['fe_group']];
121
+            $addFields['fe_group'] = (string)$record[$enableFields['fe_group']];
122 122
         }
123 123
 
124 124
         foreach ($neededItems as $key => $value) {
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
             if ($value instanceof \DateTimeInterface) {
138 138
                 $record[$key] = $value->getTimestamp();
139 139
             } elseif (\is_bool($value) || 'start_time' === $key || 'end_time' === $key) {
140
-                $record[$key] = (int) $value;
140
+                $record[$key] = (int)$value;
141 141
             } elseif (null === $value) {
142 142
                 $record[$key] = '';
143 143
             }
Please login to merge, or discard this patch.
Classes/Service/TimeSelectionWizard.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@
 block discarded – undo
34 34
         if ('' === $id && '' === $name) {
35 35
             return '';
36 36
         }
37
-        $times = $this->getTimes((int) $params['pid']);
37
+        $times = $this->getTimes((int)$params['pid']);
38 38
         if (!$times) {
39 39
             return '';
40 40
         }
Please login to merge, or discard this patch.
Classes/Service/TcaInformation.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
 
35 35
         $previewLimit = 10;
36 36
         if (isset($configuration['fieldConf']['config']['items'])) {
37
-            $previewLimit = (int) $configuration['fieldConf']['config']['items'];
37
+            $previewLimit = (int)$configuration['fieldConf']['config']['items'];
38 38
         }
39 39
 
40 40
         $indexService = GeneralUtility::makeInstance(IndexerService::class);
@@ -77,13 +77,13 @@  discard block
 block discarded – undo
77 77
         $items = [];
78 78
         foreach ($events as $event) {
79 79
             $startDateStamp = $event['start_date'] instanceof \DateTimeInterface ? $event['start_date']->getTimestamp() : $event['start_date'];
80
-            $startDate = \strftime(DateTimeUtility::FORMAT_DATE_BACKEND, (int) $startDateStamp);
80
+            $startDate = \strftime(DateTimeUtility::FORMAT_DATE_BACKEND, (int)$startDateStamp);
81 81
             $endDateStamp = $event['end_date'] instanceof \DateTimeInterface ? $event['end_date']->getTimestamp() : $event['end_date'];
82
-            $endDate = \strftime(DateTimeUtility::FORMAT_DATE_BACKEND, (int) $endDateStamp);
82
+            $endDate = \strftime(DateTimeUtility::FORMAT_DATE_BACKEND, (int)$endDateStamp);
83 83
             $entry = $startDate . ' - ' . $endDate;
84 84
             if (!$event['all_day']) {
85 85
                 $start = BackendUtility::time($event['start_time'] % DateTimeUtility::SECONDS_DAY, false);
86
-                if (AbstractTimeTable::DAY_END === (int) $event['end_time']) {
86
+                if (AbstractTimeTable::DAY_END === (int)$event['end_time']) {
87 87
                     $end = '"' . TranslateUtility::get('openEndTime') . '"';
88 88
                 } else {
89 89
                     $end = BackendUtility::time($event['end_time'] % DateTimeUtility::SECONDS_DAY, false);
Please login to merge, or discard this patch.
Classes/Service/RecurrenceService.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -66,7 +66,7 @@  discard block
 block discarded – undo
66 66
     {
67 67
         // clone and reset and move to next month
68 68
         $dateTime = clone $date;
69
-        $dateTime->setDate((int) $dateTime->format('Y'), (int) $dateTime->format('m'), 1);
69
+        $dateTime->setDate((int)$dateTime->format('Y'), (int)$dateTime->format('m'), 1);
70 70
         $dateTime->modify($modify);
71 71
 
72 72
         $days = $this->getValidDays($day);
@@ -162,15 +162,15 @@  discard block
 block discarded – undo
162 162
     protected function findDayInCurrentMonth(\DateTime $dateTime, string $direction, array $validDays, int $position = 1)
163 163
     {
164 164
         if (self::DIRECTION_UP === $direction) {
165
-            $dateTime->setDate((int) $dateTime->format('Y'), (int) $dateTime->format('m'), 1);
165
+            $dateTime->setDate((int)$dateTime->format('Y'), (int)$dateTime->format('m'), 1);
166 166
             $modify = '+1 day';
167 167
         } else {
168
-            $dateTime->setDate((int) $dateTime->format('Y'), (int) $dateTime->format('m'), (int) $dateTime->format('t'));
168
+            $dateTime->setDate((int)$dateTime->format('Y'), (int)$dateTime->format('m'), (int)$dateTime->format('t'));
169 169
             $modify = '-1 day';
170 170
         }
171 171
         $validMonth = $dateTime->format('Y-m');
172 172
         while ($dateTime->format('Y-m') === $validMonth) {
173
-            if (\in_array((int) $dateTime->format('N'), $validDays, true)) {
173
+            if (\in_array((int)$dateTime->format('N'), $validDays, true)) {
174 174
                 --$position;
175 175
                 if (0 === $position) {
176 176
                     return $dateTime;
Please login to merge, or discard this patch.
Classes/Domain/Model/Index.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
             if (null === $configuration) {
115 115
                 throw new Exception('No valid configuration for the current index: ' . $this->getUniqueRegisterKey(), 123678123);
116 116
             }
117
-            $this->originalObject = EventUtility::getOriginalRecordByConfiguration($configuration, (int) $this->getForeignUid());
117
+            $this->originalObject = EventUtility::getOriginalRecordByConfiguration($configuration, (int)$this->getForeignUid());
118 118
         }
119 119
 
120 120
         return $this->originalObject;
@@ -245,7 +245,7 @@  discard block
 block discarded – undo
245 245
      */
246 246
     public function isAllDay()
247 247
     {
248
-        return (bool) $this->allDay;
248
+        return (bool)$this->allDay;
249 249
     }
250 250
 
251 251
     /**
Please login to merge, or discard this patch.
Classes/Domain/Model/Event.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -274,7 +274,7 @@  discard block
 block discarded – undo
274 274
      */
275 275
     public function getFeedTitle(): string
276 276
     {
277
-        return (string) $this->getTitle();
277
+        return (string)$this->getTitle();
278 278
     }
279 279
 
280 280
     /**
@@ -284,7 +284,7 @@  discard block
 block discarded – undo
284 284
      */
285 285
     public function getFeedAbstract(): string
286 286
     {
287
-        return (string) $this->getFeedContent();
287
+        return (string)$this->getFeedContent();
288 288
     }
289 289
 
290 290
     /**
@@ -294,7 +294,7 @@  discard block
 block discarded – undo
294 294
      */
295 295
     public function getFeedContent(): string
296 296
     {
297
-        return (string) $this->getDescription();
297
+        return (string)$this->getDescription();
298 298
     }
299 299
 
300 300
     /**
@@ -304,7 +304,7 @@  discard block
 block discarded – undo
304 304
      */
305 305
     public function getFeedLocation(): string
306 306
     {
307
-        return (string) $this->getLocation();
307
+        return (string)$this->getLocation();
308 308
     }
309 309
 
310 310
     /**
@@ -314,7 +314,7 @@  discard block
 block discarded – undo
314 314
      */
315 315
     public function getRealUrlAliasBase(): string
316 316
     {
317
-        return (string) $this->getTitle();
317
+        return (string)$this->getTitle();
318 318
     }
319 319
 
320 320
     /**
@@ -366,7 +366,7 @@  discard block
 block discarded – undo
366 366
      */
367 367
     public function getKeSearchTitle(Index $index): string
368 368
     {
369
-        return (string) $this->getTitle() . ' - ' . $index->getStartDate()
369
+        return (string)$this->getTitle() . ' - ' . $index->getStartDate()
370 370
                 ->format('d.m.Y');
371 371
     }
372 372
 
@@ -379,7 +379,7 @@  discard block
 block discarded – undo
379 379
      */
380 380
     public function getKeSearchAbstract(Index $index): string
381 381
     {
382
-        return (string) $this->getDescription();
382
+        return (string)$this->getDescription();
383 383
     }
384 384
 
385 385
     /**
@@ -391,7 +391,7 @@  discard block
 block discarded – undo
391 391
      */
392 392
     public function getKeSearchContent(Index $index): string
393 393
     {
394
-        return (string) $this->getDescription();
394
+        return (string)$this->getDescription();
395 395
     }
396 396
 
397 397
     /**
Please login to merge, or discard this patch.
Classes/Slots/EventImport.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -138,7 +138,7 @@
 block discarded – undo
138 138
      */
139 139
     protected function nl2br($string)
140 140
     {
141
-        $string = \nl2br((string) $string);
141
+        $string = \nl2br((string)$string);
142 142
 
143 143
         return \str_replace('\\n', '<br />', $string);
144 144
     }
Please login to merge, or discard this patch.
Classes/Utility/ConfigurationUtility.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
     protected static function loadConfiguration()
40 40
     {
41 41
         if (null === self::$configuration) {
42
-            self::$configuration = (array) \unserialize((string) $GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf']['calendarize']);
42
+            self::$configuration = (array)\unserialize((string)$GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf']['calendarize']);
43 43
         }
44 44
     }
45 45
 }
Please login to merge, or discard this patch.