[BUGFIX] First install lists directory errors 05/28605/4
authorErnesto Baschny <ernst@cron-it.de>
Fri, 21 Mar 2014 14:00:44 +0000 (15:00 +0100)
committerPhilipp Gampe <philipp.gampe@typo3.org>
Fri, 21 Mar 2014 15:20:19 +0000 (16:20 +0100)
For a first installer the directory structure is empty and the
first step will try to create it. We do not need to show these
as errors to the user, only if the root directory cannot be
written.

To achieve this we raise "Warnings" instead (which are
not shown in first step). To keep the Folder Structure menu
item on the left menu in the Install Tool showing a red badge
for non existing directories, we change this to also include
Warnings.

Resolves: #57152
Releases: 6.2
Change-Id: Idd628ecdf946f9befdb7fefd7a9bb7bccc175c2b
Reviewed-on: https://review.typo3.org/28605
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
Reviewed-by: Wouter Wolters
Reviewed-by: Philipp Gampe
Tested-by: Philipp Gampe
typo3/sysext/install/Classes/Controller/Action/AbstractAction.php
typo3/sysext/install/Classes/FolderStructure/DirectoryNode.php

index c7a36c2..d0763e2 100644 (file)
@@ -122,7 +122,10 @@ abstract class AbstractAction implements ActionInterface {
                $folderStatus[] = $permissionCheck->getMaskStatus('fileCreateMask');
                $folderStatus[] = $permissionCheck->getMaskStatus('folderCreateMask');
 
                $folderStatus[] = $permissionCheck->getMaskStatus('fileCreateMask');
                $folderStatus[] = $permissionCheck->getMaskStatus('folderCreateMask');
 
-               $folderStructureErrors = $statusUtility->filterBySeverity($folderStatus, 'error');
+               $folderStructureErrors = array_merge(
+                       $statusUtility->filterBySeverity($folderStatus, 'error'),
+                       $statusUtility->filterBySeverity($folderStatus, 'warning')
+               );
 
                // Context service distinguishes between standalone and backend context
                $contextService = $this->objectManager->get('TYPO3\\CMS\\Install\\Service\\ContextService');
 
                // Context service distinguishes between standalone and backend context
                $contextService = $this->objectManager->get('TYPO3\\CMS\\Install\\Service\\ContextService');
index 4ff5cc1..43097a1 100644 (file)
@@ -78,7 +78,7 @@ class DirectoryNode extends AbstractNode implements NodeInterface {
        public function getStatus() {
                $result = array();
                if (!$this->exists()) {
        public function getStatus() {
                $result = array();
                if (!$this->exists()) {
-                       $status = new Status\ErrorStatus();
+                       $status = new Status\WarningStatus();
                        $status->setTitle('Directory ' . $this->getRelativePathBelowSiteRoot() . ' does not exist');
                        $status->setMessage('The Install Tool can try to create it');
                        $result[] = $status;
                        $status->setTitle('Directory ' . $this->getRelativePathBelowSiteRoot() . ' does not exist');
                        $status->setMessage('The Install Tool can try to create it');
                        $result[] = $status;