[BUGFIX] Skip language -1 in preview url generation 12/58612/3
authorGeorg Ringer <georg.ringer@gmail.com>
Thu, 11 Oct 2018 06:49:08 +0000 (08:49 +0200)
committerAnja Leichsenring <aleichsenring@ab-softlab.de>
Thu, 8 Nov 2018 20:21:38 +0000 (21:21 +0100)
Resolves: #86623
Releases: master
Change-Id: Ic7e6c8dd5b7232f2ee2e3f84664b25835e782677
Reviewed-on: https://review.typo3.org/58612
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Raphael Graf <r@undefined.ch>
Tested-by: Raphael Graf <r@undefined.ch>
Reviewed-by: Alexander Grein <alexander.grein@gmail.com>
Tested-by: Alexander Grein <alexander.grein@gmail.com>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
typo3/sysext/backend/Classes/Controller/EditDocumentController.php

index 1efa519..c1594a0 100644 (file)
@@ -1027,7 +1027,10 @@ class EditDocumentController
                 // use parent record
                 $recordId = $recordArray[$l18nPointer];
             }
-            $linkParameters['L'] = $recordArray[$languageField];
+            $language = $recordArray[$languageField];
+            if ($language > 0) {
+                $linkParameters['L'] = $language;
+            }
         }
 
         // map record data to GET parameters