@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | * |
61 | 61 | * @var \EWW\Dpf\Domain\Model\DocumentType |
62 | 62 | */ |
63 | - protected $documentType = null; |
|
63 | + protected $documentType = NULL; |
|
64 | 64 | |
65 | 65 | /** |
66 | 66 | * objectIdentifier |
@@ -95,14 +95,14 @@ discard block |
||
95 | 95 | * |
96 | 96 | * @var boolean |
97 | 97 | */ |
98 | - protected $changed = false; |
|
98 | + protected $changed = FALSE; |
|
99 | 99 | |
100 | 100 | /** |
101 | 101 | * valid |
102 | 102 | * |
103 | 103 | * @var boolean |
104 | 104 | */ |
105 | - protected $valid = false; |
|
105 | + protected $valid = FALSE; |
|
106 | 106 | |
107 | 107 | /** |
108 | 108 | * |
@@ -119,7 +119,7 @@ discard block |
||
119 | 119 | /** |
120 | 120 | * @var bool $suggestion |
121 | 121 | */ |
122 | - protected $suggestion = false; |
|
122 | + protected $suggestion = FALSE; |
|
123 | 123 | |
124 | 124 | /** |
125 | 125 | * creator |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | * |
186 | 186 | * @var \DateTime |
187 | 187 | */ |
188 | - protected $embargoDate = null; |
|
188 | + protected $embargoDate = NULL; |
|
189 | 189 | |
190 | 190 | /** |
191 | 191 | * newlyAssignedFobIdentifiers |
@@ -197,7 +197,7 @@ discard block |
||
197 | 197 | /** |
198 | 198 | * @var bool |
199 | 199 | */ |
200 | - protected $stateChange = false; |
|
200 | + protected $stateChange = FALSE; |
|
201 | 201 | |
202 | 202 | /** |
203 | 203 | * file |
@@ -205,7 +205,7 @@ discard block |
||
205 | 205 | * @var \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\EWW\Dpf\Domain\Model\File> |
206 | 206 | * @TYPO3\CMS\Extbase\Annotation\ORM\Cascade("remove") |
207 | 207 | */ |
208 | - protected $file = null; |
|
208 | + protected $file = NULL; |
|
209 | 209 | |
210 | 210 | const TRANSFER_ERROR = "ERROR"; |
211 | 211 | const TRANSFER_QUEUED = "QUEUED"; |
@@ -378,7 +378,7 @@ discard block |
||
378 | 378 | public function setObjectIdentifier($objectIdentifier) |
379 | 379 | { |
380 | 380 | // Due to uniqe key uc_object_identifier, which should ignore empty object identifiers. |
381 | - $this->objectIdentifier = empty($objectIdentifier)? null : $objectIdentifier; |
|
381 | + $this->objectIdentifier = empty($objectIdentifier)? NULL : $objectIdentifier; |
|
382 | 382 | } |
383 | 383 | |
384 | 384 | /** |
@@ -561,7 +561,7 @@ discard block |
||
561 | 561 | return $file; |
562 | 562 | } |
563 | 563 | } |
564 | - return null; |
|
564 | + return NULL; |
|
565 | 565 | } |
566 | 566 | |
567 | 567 | /** |
@@ -575,7 +575,7 @@ discard block |
||
575 | 575 | return $file; |
576 | 576 | } |
577 | 577 | } |
578 | - return null; |
|
578 | + return NULL; |
|
579 | 579 | } |
580 | 580 | |
581 | 581 | /** |
@@ -587,12 +587,12 @@ discard block |
||
587 | 587 | foreach ($this->getFile() as $file) { |
588 | 588 | /** @var File $file */ |
589 | 589 | if (!$file->isFileGroupDeleted()) { |
590 | - return true; |
|
590 | + return TRUE; |
|
591 | 591 | } |
592 | 592 | } |
593 | 593 | } |
594 | 594 | |
595 | - return false; |
|
595 | + return FALSE; |
|
596 | 596 | } |
597 | 597 | |
598 | 598 | /** |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | * @var \EWW\Dpf\Services\Document\EditingLockService |
53 | 53 | * @TYPO3\CMS\Extbase\Annotation\Inject |
54 | 54 | */ |
55 | - protected $editingLockService = null; |
|
55 | + protected $editingLockService = NULL; |
|
56 | 56 | |
57 | 57 | /** |
58 | 58 | * documentManager |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | * @var \EWW\Dpf\Services\Document\DocumentManager |
61 | 61 | * @TYPO3\CMS\Extbase\Annotation\Inject |
62 | 62 | */ |
63 | - protected $documentManager = null; |
|
63 | + protected $documentManager = NULL; |
|
64 | 64 | |
65 | 65 | /** |
66 | 66 | * bookmarkRepository |
@@ -68,7 +68,7 @@ discard block |
||
68 | 68 | * @var \EWW\Dpf\Domain\Repository\BookmarkRepository |
69 | 69 | * @TYPO3\CMS\Extbase\Annotation\Inject |
70 | 70 | */ |
71 | - protected $bookmarkRepository = null; |
|
71 | + protected $bookmarkRepository = NULL; |
|
72 | 72 | |
73 | 73 | /** |
74 | 74 | * clientConfigurationManager |
@@ -125,10 +125,10 @@ discard block |
||
125 | 125 | */ |
126 | 126 | public function editAction( |
127 | 127 | \EWW\Dpf\Domain\Model\DocumentForm $documentForm, |
128 | - bool $suggestMod = false, |
|
128 | + bool $suggestMod = FALSE, |
|
129 | 129 | $activeGroup = '', |
130 | 130 | $activeGroupIndex = 0, |
131 | - $addCurrentFeUser = true |
|
131 | + $addCurrentFeUser = TRUE |
|
132 | 132 | ) |
133 | 133 | { |
134 | 134 | /** @var \EWW\Dpf\Domain\Model\Document $document */ |
@@ -157,7 +157,7 @@ discard block |
||
157 | 157 | } |
158 | 158 | |
159 | 159 | $this->addFlashMessage($message, '', AbstractMessage::ERROR); |
160 | - $this->redirect('showDetails', 'Document', null, ['document' => $document]); |
|
160 | + $this->redirect('showDetails', 'Document', NULL, ['document' => $document]); |
|
161 | 161 | return FALSE; |
162 | 162 | } |
163 | 163 | |
@@ -186,7 +186,7 @@ discard block |
||
186 | 186 | $workingCopy = $this->documentRepository->findByUid($documentForm->getDocumentUid()); |
187 | 187 | |
188 | 188 | if ($workingCopy->isTemporary()) { |
189 | - $workingCopy->setTemporary(false); |
|
189 | + $workingCopy->setTemporary(FALSE); |
|
190 | 190 | } |
191 | 191 | |
192 | 192 | $newDocument = $this->objectManager->get(Document::class); |
@@ -206,7 +206,7 @@ discard block |
||
206 | 206 | $newDocument->setLinkedUid($document->getUid()); |
207 | 207 | } |
208 | 208 | |
209 | - $newDocument->setSuggestion(true); |
|
209 | + $newDocument->setSuggestion(TRUE); |
|
210 | 210 | $newDocument->setComment($document->getComment()); |
211 | 211 | |
212 | 212 | if ($restore) { |
@@ -245,7 +245,7 @@ discard block |
||
245 | 245 | '' |
246 | 246 | ); |
247 | 247 | } |
248 | - $this->addFlashMessage($flashMessage, '', AbstractMessage::OK, true); |
|
248 | + $this->addFlashMessage($flashMessage, '', AbstractMessage::OK, TRUE); |
|
249 | 249 | |
250 | 250 | $notifier = $this->objectManager->get(Notifier::class); |
251 | 251 | $notifier->sendAdminNewSuggestionNotification($newDocument); |
@@ -281,7 +281,7 @@ discard block |
||
281 | 281 | |
282 | 282 | } catch (\Throwable $t) { |
283 | 283 | $severity = \TYPO3\CMS\Core\Messaging\AbstractMessage::ERROR; |
284 | - $this->addFlashMessage("Failed", '', $severity,false); |
|
284 | + $this->addFlashMessage("Failed", '', $severity,FALSE); |
|
285 | 285 | } |
286 | 286 | |
287 | 287 | $this->redirectToDocumentList(); |
@@ -292,7 +292,7 @@ discard block |
||
292 | 292 | { |
293 | 293 | if ($this->request->getArgument('documentData')['suggestMod']) { |
294 | 294 | $restore = $this->request->getArgument('documentData')['suggestRestore']; |
295 | - $this->forward('createSuggestionDocument', null, null, ['documentForm' => $documentForm, 'restore' => $restore]); |
|
295 | + $this->forward('createSuggestionDocument', NULL, NULL, ['documentForm' => $documentForm, 'restore' => $restore]); |
|
296 | 296 | } |
297 | 297 | |
298 | 298 | $backToList = $this->request->getArgument('documentData')['backToList']; |
@@ -302,7 +302,7 @@ discard block |
||
302 | 302 | } elseif ($this->request->hasArgument('saveWorkingCopy')) { |
303 | 303 | $saveMode = 'saveWorkingCopy'; |
304 | 304 | } else { |
305 | - $saveMode = null; |
|
305 | + $saveMode = NULL; |
|
306 | 306 | } |
307 | 307 | |
308 | 308 | $this->forward( |
@@ -326,7 +326,7 @@ discard block |
||
326 | 326 | * @throws \TYPO3\CMS\Extbase\Mvc\Exception\StopActionException |
327 | 327 | * @throws \TYPO3\CMS\Extbase\Mvc\Exception\UnsupportedRequestTypeException |
328 | 328 | */ |
329 | - public function updateDocumentAction(\EWW\Dpf\Domain\Model\DocumentForm $documentForm, $saveMode = null, $backToList = false) |
|
329 | + public function updateDocumentAction(\EWW\Dpf\Domain\Model\DocumentForm $documentForm, $saveMode = NULL, $backToList = FALSE) |
|
330 | 330 | { |
331 | 331 | try { |
332 | 332 | /** @var \EWW\Dpf\Domain\Model\Document $document */ |
@@ -348,8 +348,8 @@ discard block |
||
348 | 348 | $this->addFlashMessage($message, '', AbstractMessage::ERROR); |
349 | 349 | |
350 | 350 | $this->redirect('cancelEdit', |
351 | - null, |
|
352 | - null, |
|
351 | + NULL, |
|
352 | + NULL, |
|
353 | 353 | ['documentUid' => $document->getUid(), 'backToList' => $backToList] |
354 | 354 | ); |
355 | 355 | /* |
@@ -367,13 +367,13 @@ discard block |
||
367 | 367 | /** @var \EWW\Dpf\Domain\Model\Document $updateDocument */ |
368 | 368 | $updateDocument = $documentMapper->getDocument($documentForm); |
369 | 369 | |
370 | - $saveWorkingCopy = false; |
|
371 | - $workflowTransition = null; |
|
370 | + $saveWorkingCopy = FALSE; |
|
371 | + $workflowTransition = NULL; |
|
372 | 372 | |
373 | 373 | // Convert the temporary copy into a local working copy if needed. |
374 | 374 | if ( $updateDocument->isTemporaryCopy() && $saveMode == 'saveWorkingCopy') { |
375 | - $saveWorkingCopy = true; |
|
376 | - $updateDocument->setTemporary(false); |
|
375 | + $saveWorkingCopy = TRUE; |
|
376 | + $updateDocument->setTemporary(FALSE); |
|
377 | 377 | $workflowTransition = DocumentWorkflow::TRANSITION_IN_PROGRESS; |
378 | 378 | } elseif ($updateDocument->isTemporaryCopy() && $saveMode == 'saveAndUpdate') { |
379 | 379 | $workflowTransition = DocumentWorkflow::TRANSITION_REMOTE_UPDATE; |
@@ -481,8 +481,8 @@ discard block |
||
481 | 481 | $this->redirectToDocumentList(); |
482 | 482 | } else { |
483 | 483 | $this->redirect('cancelEdit', |
484 | - null, |
|
485 | - null, |
|
484 | + NULL, |
|
485 | + NULL, |
|
486 | 486 | ['documentUid' => $updateDocument->getUid(), 'backToList' => $backToList] |
487 | 487 | ); |
488 | 488 | // $this->redirect('showDetails', 'Document', null, ['document' => $updateDocument]); |
@@ -507,13 +507,13 @@ discard block |
||
507 | 507 | |
508 | 508 | $exceptionMsg[] = LocalizationUtility::translate($key, 'dpf'); |
509 | 509 | |
510 | - $this->addFlashMessage(implode(" ", $exceptionMsg), '', $severity, true); |
|
510 | + $this->addFlashMessage(implode(" ", $exceptionMsg), '', $severity, TRUE); |
|
511 | 511 | $this->redirect('cancelEdit', |
512 | - null, |
|
513 | - null, |
|
512 | + NULL, |
|
513 | + NULL, |
|
514 | 514 | ['documentUid' => $updateDocument->getUid(), 'backToList' => $backToList] |
515 | 515 | ); |
516 | - $this->redirect('showDetails', 'Document', null, ['document' => $updateDocument]); |
|
516 | + $this->redirect('showDetails', 'Document', NULL, ['document' => $updateDocument]); |
|
517 | 517 | } |
518 | 518 | } |
519 | 519 | |
@@ -530,7 +530,7 @@ discard block |
||
530 | 530 | $args[] = $document->getTitle(); |
531 | 531 | $message = LocalizationUtility::translate($key, 'dpf', $args); |
532 | 532 | $this->addFlashMessage($message, '', AbstractMessage::ERROR); |
533 | - $this->redirect('showDetails', 'Document', null, ['document' => $document]); |
|
533 | + $this->redirect('showDetails', 'Document', NULL, ['document' => $document]); |
|
534 | 534 | return FALSE; |
535 | 535 | } |
536 | 536 | |
@@ -544,7 +544,7 @@ discard block |
||
544 | 544 | $message, |
545 | 545 | '', |
546 | 546 | $severity, |
547 | - true |
|
547 | + TRUE |
|
548 | 548 | ); |
549 | 549 | |
550 | 550 | } catch (\TYPO3\CMS\Extbase\Mvc\Exception\StopActionException $e) { |
@@ -566,7 +566,7 @@ discard block |
||
566 | 566 | implode(" ", $message), |
567 | 567 | '', |
568 | 568 | $severity, |
569 | - true |
|
569 | + TRUE |
|
570 | 570 | ); |
571 | 571 | } |
572 | 572 | |
@@ -584,7 +584,7 @@ discard block |
||
584 | 584 | * |
585 | 585 | * @return void |
586 | 586 | */ |
587 | - public function cancelEditAction($documentUid = 0, $backToList = false) |
|
587 | + public function cancelEditAction($documentUid = 0, $backToList = FALSE) |
|
588 | 588 | { |
589 | 589 | if (empty($documentUid) || $backToList) { |
590 | 590 | $this->redirectToDocumentList(); |
@@ -592,7 +592,7 @@ discard block |
||
592 | 592 | |
593 | 593 | /** @var $document \EWW\Dpf\Domain\Model\Document */ |
594 | 594 | $document = $this->documentRepository->findByUid($documentUid); |
595 | - $this->redirect('showDetails', 'Document', null, ['document' => $document]); |
|
595 | + $this->redirect('showDetails', 'Document', NULL, ['document' => $document]); |
|
596 | 596 | } |
597 | 597 | |
598 | 598 | /** |
@@ -624,14 +624,14 @@ discard block |
||
624 | 624 | * @throws \TYPO3\CMS\Extbase\Mvc\Exception\StopActionException |
625 | 625 | * @throws \TYPO3\CMS\Extbase\Mvc\Exception\UnsupportedRequestTypeException |
626 | 626 | */ |
627 | - protected function redirectToDocumentList($message = null) |
|
627 | + protected function redirectToDocumentList($message = NULL) |
|
628 | 628 | { |
629 | 629 | list($action, $controller, $redirectUri) = $this->session->getStoredAction(); |
630 | 630 | |
631 | 631 | if ($redirectUri) { |
632 | 632 | $this->redirectToUri($redirectUri); |
633 | 633 | } else { |
634 | - $this->redirect($action, $controller, null, array('message' => $message)); |
|
634 | + $this->redirect($action, $controller, NULL, array('message' => $message)); |
|
635 | 635 | } |
636 | 636 | } |
637 | 637 | } |
@@ -199,22 +199,22 @@ discard block |
||
199 | 199 | // allow dissemination if a request parameter 'deliverInactive' has the secret |
200 | 200 | // TYPOScript configuration value 'deliverInactiveSecretKey' |
201 | 201 | |
202 | - $restrictToActiveDocuments = true; |
|
202 | + $restrictToActiveDocuments = TRUE; |
|
203 | 203 | $deliverInactiveSecretKey = $this->settings['deliverInactiveSecretKey']; |
204 | 204 | |
205 | 205 | if ($deliverInactiveSecretKey == $piVars['deliverInactive']) { |
206 | - $restrictToActiveDocuments = false; |
|
206 | + $restrictToActiveDocuments = FALSE; |
|
207 | 207 | } |
208 | 208 | |
209 | - if (true === $isRepositoryObject) { |
|
210 | - if (true === $restrictToActiveDocuments) { |
|
209 | + if (TRUE === $isRepositoryObject) { |
|
210 | + if (TRUE === $restrictToActiveDocuments) { |
|
211 | 211 | // if restriction applies, check object state before dissemination |
212 | 212 | $objectProfileURI = rtrim('http://' . $fedoraHost, |
213 | 213 | "/") . '/fedora/objects/' . $piVars['qid'] . '?format=XML'; |
214 | 214 | $objectProfileXML = file_get_contents($objectProfileURI); |
215 | - if (false !== $objectProfileXML) { |
|
215 | + if (FALSE !== $objectProfileXML) { |
|
216 | 216 | $objectProfileDOM = new \DOMDocument('1.0', 'UTF-8'); |
217 | - if (true === $objectProfileDOM->loadXML($objectProfileXML)) { |
|
217 | + if (TRUE === $objectProfileDOM->loadXML($objectProfileXML)) { |
|
218 | 218 | $objectState = $objectProfileDOM->getElementsByTagName('objState')[0]; |
219 | 219 | if ('I' === $objectState->nodeValue) { |
220 | 220 | $this->response->setStatus(403); |
@@ -235,29 +235,29 @@ discard block |
||
235 | 235 | // get remote header and set it before passtrough |
236 | 236 | $headers = get_headers($path); |
237 | 237 | |
238 | - if (false === $headers) { |
|
238 | + if (FALSE === $headers) { |
|
239 | 239 | $this->response->setStatus(500); |
240 | 240 | return 'Error while fetching headers'; |
241 | 241 | } |
242 | 242 | |
243 | - $contentDispFlag = false; |
|
244 | - $contentTypeFlag = false; |
|
243 | + $contentDispFlag = FALSE; |
|
244 | + $contentTypeFlag = FALSE; |
|
245 | 245 | |
246 | 246 | foreach ($headers as $value) { |
247 | 247 | |
248 | - if (false !== stripos($value, 'Content-Disposition')) { |
|
248 | + if (FALSE !== stripos($value, 'Content-Disposition')) { |
|
249 | 249 | header($value); |
250 | - $contentDispFlag = true; |
|
250 | + $contentDispFlag = TRUE; |
|
251 | 251 | continue; |
252 | 252 | } |
253 | 253 | |
254 | - if (false !== stripos($value, 'Content-Type')) { |
|
254 | + if (FALSE !== stripos($value, 'Content-Type')) { |
|
255 | 255 | header($value); |
256 | - $contentTypeFlag = true; |
|
256 | + $contentTypeFlag = TRUE; |
|
257 | 257 | continue; |
258 | 258 | } |
259 | 259 | |
260 | - if (false !== stripos($value, 'Content-Length')) { |
|
260 | + if (FALSE !== stripos($value, 'Content-Length')) { |
|
261 | 261 | header($value); |
262 | 262 | continue; |
263 | 263 | } |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | * @var \EWW\Dpf\Domain\Repository\MetadataGroupRepository |
32 | 32 | * @TYPO3\CMS\Extbase\Annotation\Inject |
33 | 33 | */ |
34 | - protected $metadataGroupRepository = null; |
|
34 | + protected $metadataGroupRepository = NULL; |
|
35 | 35 | |
36 | 36 | /** |
37 | 37 | * metadataObjectRepository |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | * @var \EWW\Dpf\Domain\Repository\MetadataObjectRepository |
40 | 40 | * @TYPO3\CMS\Extbase\Annotation\Inject |
41 | 41 | */ |
42 | - protected $metadataObjectRepository = null; |
|
42 | + protected $metadataObjectRepository = NULL; |
|
43 | 43 | |
44 | 44 | /** |
45 | 45 | * fisDataService |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | * @var \EWW\Dpf\Services\FeUser\FisDataService |
48 | 48 | * @TYPO3\CMS\Extbase\Annotation\Inject |
49 | 49 | */ |
50 | - protected $fisDataService = null; |
|
50 | + protected $fisDataService = NULL; |
|
51 | 51 | |
52 | 52 | /** |
53 | 53 | * |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | $groupItem->setGroupType($group->getGroupType()); |
91 | 91 | $groupItem->setMandatory($group->getMandatory()); |
92 | 92 | $groupItem->setMaxIteration($group->getMaxIteration()); |
93 | - $groupItem->setEmptyGroup(true); |
|
93 | + $groupItem->setEmptyGroup(TRUE); |
|
94 | 94 | |
95 | 95 | if ($this->security->getFisPersId()) { |
96 | 96 | $this->view->assign('fisPersId', $this->security->getFisPersId()); |
@@ -232,7 +232,7 @@ discard block |
||
232 | 232 | |
233 | 233 | return json_encode( |
234 | 234 | array( |
235 | - 'error' => false, |
|
235 | + 'error' => FALSE, |
|
236 | 236 | 'fedoraPid' => $fedoraPid, |
237 | 237 | 'value' => $urn, |
238 | 238 | ) |
@@ -241,9 +241,9 @@ discard block |
||
241 | 241 | } catch (\Exception $exception) { |
242 | 242 | return json_encode( |
243 | 243 | array( |
244 | - 'error' => true, |
|
245 | - 'fedoraPid' => null, |
|
246 | - 'value' => null, |
|
244 | + 'error' => TRUE, |
|
245 | + 'fedoraPid' => NULL, |
|
246 | + 'value' => NULL, |
|
247 | 247 | ) |
248 | 248 | ); |
249 | 249 | } |
@@ -51,7 +51,7 @@ discard block |
||
51 | 51 | * @var \EWW\Dpf\Security\Security |
52 | 52 | * @TYPO3\CMS\Extbase\Annotation\Inject |
53 | 53 | */ |
54 | - protected $security = null; |
|
54 | + protected $security = NULL; |
|
55 | 55 | |
56 | 56 | /** |
57 | 57 | * documentRepository |
@@ -59,7 +59,7 @@ discard block |
||
59 | 59 | * @var \EWW\Dpf\Domain\Repository\DocumentRepository |
60 | 60 | * @TYPO3\CMS\Extbase\Annotation\Inject |
61 | 61 | */ |
62 | - protected $documentRepository = null; |
|
62 | + protected $documentRepository = NULL; |
|
63 | 63 | |
64 | 64 | /** |
65 | 65 | * frontendUserRepository |
@@ -67,7 +67,7 @@ discard block |
||
67 | 67 | * @var \EWW\Dpf\Domain\Repository\FrontendUserRepository |
68 | 68 | * @TYPO3\CMS\Extbase\Annotation\Inject |
69 | 69 | */ |
70 | - protected $frontendUserRepository = null; |
|
70 | + protected $frontendUserRepository = NULL; |
|
71 | 71 | |
72 | 72 | /** |
73 | 73 | * documentManager |
@@ -75,7 +75,7 @@ discard block |
||
75 | 75 | * @var \EWW\Dpf\Services\Document\DocumentManager |
76 | 76 | * @TYPO3\CMS\Extbase\Annotation\Inject |
77 | 77 | */ |
78 | - protected $documentManager = null; |
|
78 | + protected $documentManager = NULL; |
|
79 | 79 | |
80 | 80 | /** |
81 | 81 | * clientRepository |
@@ -99,16 +99,16 @@ discard block |
||
99 | 99 | * @var \TYPO3\CMS\Extbase\SignalSlot\Dispatcher |
100 | 100 | * @TYPO3\CMS\Extbase\Annotation\Inject |
101 | 101 | */ |
102 | - protected $signalSlotDispatcher = null; |
|
102 | + protected $signalSlotDispatcher = NULL; |
|
103 | 103 | |
104 | 104 | /** |
105 | 105 | * logger |
106 | 106 | * |
107 | 107 | * @var \TYPO3\CMS\Core\Log\Logger |
108 | 108 | */ |
109 | - protected $logger = null; |
|
109 | + protected $logger = NULL; |
|
110 | 110 | |
111 | - protected $frontendUser = null; |
|
111 | + protected $frontendUser = NULL; |
|
112 | 112 | |
113 | 113 | protected $validActions = [ |
114 | 114 | 'show', 'create', 'suggestion', 'importDoiWithoutSaving', |
@@ -129,9 +129,9 @@ discard block |
||
129 | 129 | |
130 | 130 | if ($frontendUser) { |
131 | 131 | $this->frontendUser = $frontendUser; |
132 | - return true; |
|
132 | + return TRUE; |
|
133 | 133 | } else { |
134 | - return false; |
|
134 | + return FALSE; |
|
135 | 135 | } |
136 | 136 | } |
137 | 137 | |
@@ -258,7 +258,7 @@ discard block |
||
258 | 258 | $doc->setProcessNumber($processNumber); |
259 | 259 | } |
260 | 260 | |
261 | - if ($this->documentManager->update($doc, null,true)) { |
|
261 | + if ($this->documentManager->update($doc, NULL,TRUE)) { |
|
262 | 262 | return '{"success": "Document '.$document.' added '.$id.'"}'; |
263 | 263 | } else { |
264 | 264 | return '{"failed": Could not update the Document"}'; |
@@ -289,7 +289,7 @@ discard block |
||
289 | 289 | * @param bool $restore |
290 | 290 | * @return string |
291 | 291 | */ |
292 | - public function suggestionAction($document, $json, $comment, $token, $restore = false) { |
|
292 | + public function suggestionAction($document, $json, $comment, $token, $restore = FALSE) { |
|
293 | 293 | |
294 | 294 | if ($this->checkToken($token)) { |
295 | 295 | |
@@ -298,7 +298,7 @@ discard block |
||
298 | 298 | return '{"error": "Invalid data in parameter json."}'; |
299 | 299 | } |
300 | 300 | } else { |
301 | - if (empty($json) || json_decode($json,true) === []) { |
|
301 | + if (empty($json) || json_decode($json,TRUE) === []) { |
|
302 | 302 | return '{"error": "Parameter json can not be empty."}'; |
303 | 303 | } |
304 | 304 | if (is_null(json_decode($json))) { |
@@ -525,14 +525,14 @@ discard block |
||
525 | 525 | * @param bool $force |
526 | 526 | * @return string |
527 | 527 | */ |
528 | - public function importBibtexWithoutSavingAction($bibtex, $token, $force = false) { |
|
528 | + public function importBibtexWithoutSavingAction($bibtex, $token, $force = FALSE) { |
|
529 | 529 | |
530 | 530 | if ($this->checkToken($token)) { |
531 | 531 | $importer = $this->objectManager->get(BibTexFileImporter::class); |
532 | 532 | $importer->deactivateProcessNumberGeneration(); |
533 | 533 | |
534 | 534 | try { |
535 | - $externalMetadata = $importer->loadFile($bibtex, $this->settings['bibTexMandatoryFields'], true); |
|
535 | + $externalMetadata = $importer->loadFile($bibtex, $this->settings['bibTexMandatoryFields'], TRUE); |
|
536 | 536 | $mandatoryErrors = $importer->getMandatoryErrors(); |
537 | 537 | } catch (\Throwable $throwable) { |
538 | 538 | return '{"failed": "' . $throwable->getMessage() . '"}'; |
@@ -605,7 +605,7 @@ discard block |
||
605 | 605 | * @param bool $force |
606 | 606 | * @return string |
607 | 607 | */ |
608 | - public function importRisWithoutSavingAction($ris, $token, $force = false) { |
|
608 | + public function importRisWithoutSavingAction($ris, $token, $force = FALSE) { |
|
609 | 609 | |
610 | 610 | if ($this->checkToken($token)) { |
611 | 611 | /** @var FileImporter $fileImporter */ |
@@ -613,7 +613,7 @@ discard block |
||
613 | 613 | $importer->deactivateProcessNumberGeneration(); |
614 | 614 | |
615 | 615 | try { |
616 | - $externalMetadata = $importer->loadFile($ris, $this->settings['riswosMandatoryFields'], true); |
|
616 | + $externalMetadata = $importer->loadFile($ris, $this->settings['riswosMandatoryFields'], TRUE); |
|
617 | 617 | $mandatoryErrors = $importer->getMandatoryErrors(); |
618 | 618 | } catch (\Throwable $throwable) { |
619 | 619 | return '{"failed": "' . $throwable->getMessage() . '"}'; |
@@ -688,7 +688,7 @@ discard block |
||
688 | 688 | if ($missingArguments) { |
689 | 689 | $this->throwStatus( |
690 | 690 | 400, |
691 | - null, |
|
691 | + NULL, |
|
692 | 692 | '{"error": "Missing parameters: '.implode(", ", $missingArguments).'"}' |
693 | 693 | ); |
694 | 694 | } |
@@ -709,7 +709,7 @@ discard block |
||
709 | 709 | if (empty($actionName)) { |
710 | 710 | $this->throwStatus( |
711 | 711 | 400, |
712 | - null, |
|
712 | + NULL, |
|
713 | 713 | '{"error": "No action has been specified"}' |
714 | 714 | ); |
715 | 715 | |
@@ -718,7 +718,7 @@ discard block |
||
718 | 718 | if (!in_array($actionName, $this->validActions)) { |
719 | 719 | $this->throwStatus( |
720 | 720 | 400, |
721 | - null, |
|
721 | + NULL, |
|
722 | 722 | '{"error": "An invalid action hes been called: '.$actionName.'"}' |
723 | 723 | ); |
724 | 724 | } |
@@ -21,9 +21,9 @@ discard block |
||
21 | 21 | class DocumentFormController extends AbstractDocumentFormController |
22 | 22 | { |
23 | 23 | |
24 | - protected function redirectToList($message = null) |
|
24 | + protected function redirectToList($message = NULL) |
|
25 | 25 | { |
26 | - $this->redirect('list', 'DocumentForm', null, array('message' => $message)); |
|
26 | + $this->redirect('list', 'DocumentForm', NULL, array('message' => $message)); |
|
27 | 27 | } |
28 | 28 | |
29 | 29 | /** |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | * @TYPO3\CMS\Extbase\Annotation\IgnoreValidation("newDocumentForm") |
35 | 35 | * @return void |
36 | 36 | */ |
37 | - public function newAction(\EWW\Dpf\Domain\Model\DocumentForm $newDocumentForm = null, $returnDocumentId = 0) |
|
37 | + public function newAction(\EWW\Dpf\Domain\Model\DocumentForm $newDocumentForm = NULL, $returnDocumentId = 0) |
|
38 | 38 | { |
39 | 39 | $this->view->assign('documentForm', $newDocumentForm); |
40 | 40 | } |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | foreach ($newDocumentForm->getFiles() as $file) { |
51 | 51 | $uid = $file->getUID(); |
52 | 52 | if (empty($uid)) { |
53 | - $file->setDownload(true); |
|
53 | + $file->setDownload(TRUE); |
|
54 | 54 | } |
55 | 55 | $files[] = $file; |
56 | 56 | } |
@@ -90,8 +90,8 @@ discard block |
||
90 | 90 | |
91 | 91 | $message[] = \TYPO3\CMS\Extbase\Utility\LocalizationUtility::translate($key, 'dpf'); |
92 | 92 | |
93 | - $this->addFlashMessage(implode(" ", $message), '', $severity,true); |
|
94 | - $this->forward('new', 'DocumentForm', null, array('newDocumentForm' => $newDocumentForm)); |
|
93 | + $this->addFlashMessage(implode(" ", $message), '', $severity,TRUE); |
|
94 | + $this->forward('new', 'DocumentForm', NULL, array('newDocumentForm' => $newDocumentForm)); |
|
95 | 95 | } |
96 | 96 | } |
97 | 97 | } |
@@ -36,7 +36,7 @@ discard block |
||
36 | 36 | * @var \EWW\Dpf\Domain\Repository\DocumentRepository |
37 | 37 | * @TYPO3\CMS\Extbase\Annotation\Inject |
38 | 38 | */ |
39 | - protected $documentRepository = null; |
|
39 | + protected $documentRepository = NULL; |
|
40 | 40 | |
41 | 41 | /** |
42 | 42 | * fileRepository |
@@ -44,7 +44,7 @@ discard block |
||
44 | 44 | * @var \EWW\Dpf\Domain\Repository\FileRepository |
45 | 45 | * @TYPO3\CMS\Extbase\Annotation\Inject |
46 | 46 | */ |
47 | - protected $fileRepository = null; |
|
47 | + protected $fileRepository = NULL; |
|
48 | 48 | |
49 | 49 | /** |
50 | 50 | * documentTypeRepository |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | * @var \EWW\Dpf\Domain\Repository\DocumentTypeRepository |
53 | 53 | * @TYPO3\CMS\Extbase\Annotation\Inject |
54 | 54 | */ |
55 | - protected $documentTypeRepository = null; |
|
55 | + protected $documentTypeRepository = NULL; |
|
56 | 56 | |
57 | 57 | /** |
58 | 58 | * metadataGroupRepository |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | * @var \EWW\Dpf\Domain\Repository\MetadataGroupRepository |
61 | 61 | * @TYPO3\CMS\Extbase\Annotation\Inject |
62 | 62 | */ |
63 | - protected $metadataGroupRepository = null; |
|
63 | + protected $metadataGroupRepository = NULL; |
|
64 | 64 | |
65 | 65 | /** |
66 | 66 | * metadataObjectRepository |
@@ -68,7 +68,7 @@ discard block |
||
68 | 68 | * @var \EWW\Dpf\Domain\Repository\MetadataObjectRepository |
69 | 69 | * @TYPO3\CMS\Extbase\Annotation\Inject |
70 | 70 | */ |
71 | - protected $metadataObjectRepository = null; |
|
71 | + protected $metadataObjectRepository = NULL; |
|
72 | 72 | |
73 | 73 | /** |
74 | 74 | * depositLicenseLogRepository |
@@ -76,7 +76,7 @@ discard block |
||
76 | 76 | * @var \EWW\Dpf\Domain\Repository\DepositLicenseLogRepository |
77 | 77 | * @TYPO3\CMS\Extbase\Annotation\Inject |
78 | 78 | */ |
79 | - protected $depositLicenseLogRepository = null; |
|
79 | + protected $depositLicenseLogRepository = NULL; |
|
80 | 80 | |
81 | 81 | /** |
82 | 82 | * persistence manager |
@@ -92,7 +92,7 @@ discard block |
||
92 | 92 | * @var \EWW\Dpf\Services\FeUser\FisDataService |
93 | 93 | * @TYPO3\CMS\Extbase\Annotation\Inject |
94 | 94 | */ |
95 | - protected $fisDataService = null; |
|
95 | + protected $fisDataService = NULL; |
|
96 | 96 | |
97 | 97 | /** |
98 | 98 | * action list |
@@ -151,7 +151,7 @@ discard block |
||
151 | 151 | * @TYPO3\CMS\Extbase\Annotation\IgnoreValidation("newDocumentForm") |
152 | 152 | * @return void |
153 | 153 | */ |
154 | - public function newAction(DocumentForm $newDocumentForm = null, $returnDocumentId = 0) |
|
154 | + public function newAction(DocumentForm $newDocumentForm = NULL, $returnDocumentId = 0) |
|
155 | 155 | { |
156 | 156 | $this->view->assign('returnDocumentId', $returnDocumentId); |
157 | 157 | $this->view->assign('documentForm', $newDocumentForm); |
@@ -188,11 +188,11 @@ discard block |
||
188 | 188 | $documentType = $this->documentTypeRepository->findByUid($docTypeUid); |
189 | 189 | $virtualType = $documentType->getVirtualType(); |
190 | 190 | |
191 | - if (!$formDataReader->uploadError() || $virtualType === true) { |
|
191 | + if (!$formDataReader->uploadError() || $virtualType === TRUE) { |
|
192 | 192 | $this->request->setArguments($requestArguments); |
193 | 193 | } else { |
194 | 194 | $t = $docForm->getFileNames(); |
195 | - $this->redirect('list', 'DocumentForm', null, array('message' => 'UPLOAD_MAX_FILESIZE_ERROR', 'errorFiles' => $t)); |
|
195 | + $this->redirect('list', 'DocumentForm', NULL, array('message' => 'UPLOAD_MAX_FILESIZE_ERROR', 'errorFiles' => $t)); |
|
196 | 196 | } |
197 | 197 | } else { |
198 | 198 | $this->redirectToList("UPLOAD_POST_SIZE_ERROR"); |
@@ -351,11 +351,11 @@ discard block |
||
351 | 351 | $virtualType = $documentType->getVirtualType(); |
352 | 352 | |
353 | 353 | |
354 | - if (!$formDataReader->uploadError() || $virtualType === true) { |
|
354 | + if (!$formDataReader->uploadError() || $virtualType === TRUE) { |
|
355 | 355 | $this->request->setArguments($requestArguments); |
356 | 356 | } else { |
357 | 357 | $t = $docForm->getFileNames(); |
358 | - $this->redirect('list', 'Document', null, array('message' => 'UPLOAD_MAX_FILESIZE_ERROR', 'errorFiles' => $t)); |
|
358 | + $this->redirect('list', 'Document', NULL, array('message' => 'UPLOAD_MAX_FILESIZE_ERROR', 'errorFiles' => $t)); |
|
359 | 359 | } |
360 | 360 | } else { |
361 | 361 | $this->redirectToList("UPLOAD_POST_SIZE_ERROR"); |
@@ -388,7 +388,7 @@ discard block |
||
388 | 388 | // send document to index |
389 | 389 | $elasticsearchRepository->add($updateDocument, $json); |
390 | 390 | |
391 | - $updateDocument->setChanged(true); |
|
391 | + $updateDocument->setChanged(TRUE); |
|
392 | 392 | $this->documentRepository->update($updateDocument); |
393 | 393 | |
394 | 394 | // index the document |
@@ -410,7 +410,7 @@ discard block |
||
410 | 410 | $this->redirect('list'); |
411 | 411 | } |
412 | 412 | |
413 | - protected function redirectToList($message = null) |
|
413 | + protected function redirectToList($message = NULL) |
|
414 | 414 | { |
415 | 415 | $this->redirect('list'); |
416 | 416 | } |
@@ -23,7 +23,7 @@ discard block |
||
23 | 23 | * @var \TYPO3\CMS\Extbase\Object\ObjectManager |
24 | 24 | * @TYPO3\CMS\Extbase\Annotation\Inject |
25 | 25 | */ |
26 | - protected $objectManager = null; |
|
26 | + protected $objectManager = NULL; |
|
27 | 27 | |
28 | 28 | /** |
29 | 29 | * documentRepository |
@@ -31,7 +31,7 @@ discard block |
||
31 | 31 | * @var \EWW\Dpf\Domain\Repository\DocumentRepository |
32 | 32 | * @TYPO3\CMS\Extbase\Annotation\Inject |
33 | 33 | */ |
34 | - protected $documentRepository = null; |
|
34 | + protected $documentRepository = NULL; |
|
35 | 35 | |
36 | 36 | /** |
37 | 37 | * fileRepository |
@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | * @var \EWW\Dpf\Domain\Repository\FileRepository |
40 | 40 | * @TYPO3\CMS\Extbase\Annotation\Inject |
41 | 41 | */ |
42 | - protected $fileRepository = null; |
|
42 | + protected $fileRepository = NULL; |
|
43 | 43 | |
44 | 44 | /** |
45 | 45 | * bookmarkRepository |
@@ -47,7 +47,7 @@ discard block |
||
47 | 47 | * @var \EWW\Dpf\Domain\Repository\BookmarkRepository |
48 | 48 | * @TYPO3\CMS\Extbase\Annotation\Inject |
49 | 49 | */ |
50 | - protected $bookmarkRepository = null; |
|
50 | + protected $bookmarkRepository = NULL; |
|
51 | 51 | |
52 | 52 | /** |
53 | 53 | * persistence manager |
@@ -63,7 +63,7 @@ discard block |
||
63 | 63 | * @var \TYPO3\CMS\Extbase\SignalSlot\Dispatcher |
64 | 64 | * @TYPO3\CMS\Extbase\Annotation\Inject |
65 | 65 | */ |
66 | - protected $signalSlotDispatcher = null; |
|
66 | + protected $signalSlotDispatcher = NULL; |
|
67 | 67 | |
68 | 68 | /** |
69 | 69 | * notifier |
@@ -71,7 +71,7 @@ discard block |
||
71 | 71 | * @var \EWW\Dpf\Services\Email\Notifier |
72 | 72 | * @TYPO3\CMS\Extbase\Annotation\Inject |
73 | 73 | */ |
74 | - protected $notifier = null; |
|
74 | + protected $notifier = NULL; |
|
75 | 75 | |
76 | 76 | /** |
77 | 77 | * security |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | * @var \EWW\Dpf\Security\Security |
80 | 80 | * @TYPO3\CMS\Extbase\Annotation\Inject |
81 | 81 | */ |
82 | - protected $security = null; |
|
82 | + protected $security = NULL; |
|
83 | 83 | |
84 | 84 | /** |
85 | 85 | * frontendUserRepository |
@@ -87,7 +87,7 @@ discard block |
||
87 | 87 | * @var \EWW\Dpf\Domain\Repository\FrontendUserRepository |
88 | 88 | * @TYPO3\CMS\Extbase\Annotation\Inject |
89 | 89 | */ |
90 | - protected $frontendUserRepository = null; |
|
90 | + protected $frontendUserRepository = NULL; |
|
91 | 91 | |
92 | 92 | /** |
93 | 93 | * elasticSearch |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | * @var \EWW\Dpf\Services\ElasticSearch\ElasticSearch |
96 | 96 | * @TYPO3\CMS\Extbase\Annotation\Inject |
97 | 97 | */ |
98 | - protected $elasticSearch = null; |
|
98 | + protected $elasticSearch = NULL; |
|
99 | 99 | |
100 | 100 | /** |
101 | 101 | * queryBuilder |
@@ -103,7 +103,7 @@ discard block |
||
103 | 103 | * @var \EWW\Dpf\Services\ElasticSearch\QueryBuilder |
104 | 104 | * @TYPO3\CMS\Extbase\Annotation\Inject |
105 | 105 | */ |
106 | - protected $queryBuilder = null; |
|
106 | + protected $queryBuilder = NULL; |
|
107 | 107 | |
108 | 108 | /** |
109 | 109 | * Returns the localized document identifiers (uid/objectIdentifier). |
@@ -130,7 +130,7 @@ discard block |
||
130 | 130 | |
131 | 131 | $query = $this->queryBuilder->buildQuery( |
132 | 132 | 1, [], 0, |
133 | - [], [], [], null, null, |
|
133 | + [], [], [], NULL, NULL, |
|
134 | 134 | 'identifier:"'.$identifier.'"' |
135 | 135 | ); |
136 | 136 | |
@@ -158,7 +158,7 @@ discard block |
||
158 | 158 | public function read($identifier) |
159 | 159 | { |
160 | 160 | if (!$identifier) { |
161 | - return null; |
|
161 | + return NULL; |
|
162 | 162 | } |
163 | 163 | |
164 | 164 | $localizedIdentifiers = $this->resolveIdentifier($identifier); |
@@ -179,11 +179,11 @@ discard block |
||
179 | 179 | |
180 | 180 | return $document; |
181 | 181 | } catch (\Exception $exception) { |
182 | - return null; |
|
182 | + return NULL; |
|
183 | 183 | } |
184 | 184 | } |
185 | 185 | |
186 | - return null; |
|
186 | + return NULL; |
|
187 | 187 | } |
188 | 188 | |
189 | 189 | /** |
@@ -198,7 +198,7 @@ discard block |
||
198 | 198 | * @throws \TYPO3\CMS\Extbase\Persistence\Exception\UnknownObjectException |
199 | 199 | */ |
200 | 200 | public function update( |
201 | - Document $document, $workflowTransition = null, $addedFisIdOnly = false |
|
201 | + Document $document, $workflowTransition = NULL, $addedFisIdOnly = FALSE |
|
202 | 202 | ) |
203 | 203 | { |
204 | 204 | // xml data fields are limited to 64 KB |
@@ -212,7 +212,7 @@ discard block |
||
212 | 212 | |
213 | 213 | if ($workflowTransition) { |
214 | 214 | if (!$workflow->can($document, $workflowTransition)) { |
215 | - return false; |
|
215 | + return FALSE; |
|
216 | 216 | } |
217 | 217 | $workflow->apply($document, $workflowTransition); |
218 | 218 | } |
@@ -220,7 +220,7 @@ discard block |
||
220 | 220 | if ($document->isSuggestion()) { |
221 | 221 | |
222 | 222 | // if local suggestion copy |
223 | - $updateResult = false; |
|
223 | + $updateResult = FALSE; |
|
224 | 224 | |
225 | 225 | } elseif ($document->isTemporaryCopy()) { |
226 | 226 | |
@@ -268,7 +268,7 @@ discard block |
||
268 | 268 | } |
269 | 269 | $updateResult = $document->getDocumentIdentifier(); |
270 | 270 | } else { |
271 | - $updateResult = false; |
|
271 | + $updateResult = FALSE; |
|
272 | 272 | } |
273 | 273 | } else { |
274 | 274 | $this->documentRepository->update($document); |
@@ -342,13 +342,13 @@ discard block |
||
342 | 342 | * @throws \TYPO3\CMS\Extbase\Persistence\Exception\IllegalObjectTypeException |
343 | 343 | * @throws \TYPO3\CMS\Extbase\Persistence\Exception\UnknownObjectException |
344 | 344 | */ |
345 | - protected function updateRemotely($document, $workflowTransition = null) |
|
345 | + protected function updateRemotely($document, $workflowTransition = NULL) |
|
346 | 346 | { |
347 | 347 | $lastModDate = $this->getDocumentTransferManager()->getLastModDate($document->getObjectIdentifier()); |
348 | 348 | $docLastModDate = $document->getRemoteLastModDate(); |
349 | 349 | if ($lastModDate !== $docLastModDate && !empty($docLastModDate)) { |
350 | 350 | // There is a newer version in the fedora repository. |
351 | - return false; |
|
351 | + return FALSE; |
|
352 | 352 | } |
353 | 353 | |
354 | 354 | $this->documentRepository->update($document); |
@@ -367,13 +367,13 @@ discard block |
||
367 | 367 | break; |
368 | 368 | |
369 | 369 | default: |
370 | - $transferState = null; |
|
370 | + $transferState = NULL; |
|
371 | 371 | break; |
372 | 372 | } |
373 | 373 | |
374 | 374 | if ($transferState) { |
375 | 375 | if (!$this->getDocumentTransferManager()->delete($document, $transferState)) { |
376 | - return false; |
|
376 | + return FALSE; |
|
377 | 377 | } |
378 | 378 | } |
379 | 379 | |
@@ -387,10 +387,10 @@ discard block |
||
387 | 387 | return $document->getDocumentIdentifier(); |
388 | 388 | } |
389 | 389 | |
390 | - return false; |
|
390 | + return FALSE; |
|
391 | 391 | } |
392 | 392 | |
393 | - public function addSuggestion($editDocument, $restore = false, $comment = '') { |
|
393 | + public function addSuggestion($editDocument, $restore = FALSE, $comment = '') { |
|
394 | 394 | // add new document |
395 | 395 | /** @var Document $suggestionDocument */ |
396 | 396 | $suggestionDocument = $this->objectManager->get(Document::class); |
@@ -402,7 +402,7 @@ discard block |
||
402 | 402 | $suggestionDocument->setCreator($editDocument->getCreator()); |
403 | 403 | |
404 | 404 | if ($suggestionDocument->isTemporary()) { |
405 | - $suggestionDocument->setTemporary(false); |
|
405 | + $suggestionDocument->setTemporary(FALSE); |
|
406 | 406 | } |
407 | 407 | |
408 | 408 | if ($editDocument->getObjectIdentifier()) { |
@@ -411,7 +411,7 @@ discard block |
||
411 | 411 | $suggestionDocument->setLinkedUid($editDocument->getUid()); |
412 | 412 | } |
413 | 413 | |
414 | - $suggestionDocument->setSuggestion(true); |
|
414 | + $suggestionDocument->setSuggestion(TRUE); |
|
415 | 415 | if ($comment) { |
416 | 416 | $suggestionDocument->setComment($comment); |
417 | 417 | } |
@@ -423,7 +423,7 @@ discard block |
||
423 | 423 | try { |
424 | 424 | $this->documentRepository->add($suggestionDocument); |
425 | 425 | } catch (\Throwable $t) { |
426 | - return null; |
|
426 | + return NULL; |
|
427 | 427 | } |
428 | 428 | |
429 | 429 | return $suggestionDocument; |
@@ -440,9 +440,9 @@ discard block |
||
440 | 440 | $currentDate = new \DateTime('now'); |
441 | 441 | if($currentDate > $document->getEmbargoDate()){ |
442 | 442 | // embargo is expired |
443 | - return false; |
|
443 | + return FALSE; |
|
444 | 444 | } else { |
445 | - return true; |
|
445 | + return TRUE; |
|
446 | 446 | } |
447 | 447 | |
448 | 448 | } |
@@ -586,13 +586,13 @@ discard block |
||
586 | 586 | $embargoDate = $document->getEmbargoDate(); |
587 | 587 | $currentDate = new \DateTime('now'); |
588 | 588 | |
589 | - $fulltextPublished = false; |
|
589 | + $fulltextPublished = FALSE; |
|
590 | 590 | foreach ($document->getFile() as $file) { |
591 | 591 | if ($file->getStatus() != 'added') { |
592 | - $fulltextPublished = false; |
|
592 | + $fulltextPublished = FALSE; |
|
593 | 593 | break; |
594 | 594 | } else { |
595 | - $fulltextPublished = true; |
|
595 | + $fulltextPublished = TRUE; |
|
596 | 596 | } |
597 | 597 | } |
598 | 598 |
@@ -102,7 +102,7 @@ |
||
102 | 102 | * @param string $xmlData |
103 | 103 | * @return string The transformed xml |
104 | 104 | */ |
105 | - public function getTransformedOutputXML(Document $document, $xmlData = null): string |
|
105 | + public function getTransformedOutputXML(Document $document, $xmlData = NULL): string |
|
106 | 106 | { |
107 | 107 | $objectManager = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(ObjectManager::class); |
108 | 108 | $this->clientConfigurationManager = $objectManager->get(ClientConfigurationManager::class); |