From f5ddfc5f5f44f989b7202c0f6d22847c15cb564c Mon Sep 17 00:00:00 2001
From: Georg Ringer <georg.ringer@gmail.com>
Date: Thu, 9 Dec 2021 20:16:45 +0100
Subject: [PATCH] [BUGFIX] Remove workspace info from logging module if not
 needed

If EXT:workspaces is not installed, the workspace information should
also be skipped in the logging module. This makes it easier to read
and less bloated.

Resolves: #96314
Releases: main, 11.5
Change-Id: I22277ca681cc877d57686e02f36fe54e630d2f9a
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/72607
Tested-by: core-ci <typo3@b13.com>
Tested-by: Benni Mack <benni@typo3.org>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Benni Mack <benni@typo3.org>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
---
 .../Private/Partials/Content/LogEntries.html     | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/typo3/sysext/belog/Resources/Private/Partials/Content/LogEntries.html b/typo3/sysext/belog/Resources/Private/Partials/Content/LogEntries.html
index 24f13df0f7c0..06010a28bb7c 100644
--- a/typo3/sysext/belog/Resources/Private/Partials/Content/LogEntries.html
+++ b/typo3/sysext/belog/Resources/Private/Partials/Content/LogEntries.html
@@ -89,13 +89,15 @@
                                         </f:if>
                                         )
                                     </f:if>
-                                    <br>
-                                    <span class="text-muted">
-                                        <f:if condition="{belog:workspaceTitle(uid:logItem.workspaceUid)}">
-                                            <f:then><belog:workspaceTitle uid="{logItem.workspaceUid}"/></f:then>
-                                            <f:else>[{logItem.workspaceUid}]</f:else>
-                                        </f:if>
-                                    </span>
+                                    <f:if condition="{workspaces}">
+                                        <br>
+                                        <span class="text-muted">
+                                            <f:if condition="{belog:workspaceTitle(uid:logItem.workspaceUid)}">
+                                                <f:then><belog:workspaceTitle uid="{logItem.workspaceUid}"/></f:then>
+                                                <f:else>[{logItem.workspaceUid}]</f:else>
+                                            </f:if>
+                                        </span>
+                                    </f:if>
                                 </td>
                                 <td>
                                     <f:if condition="{isSubmoduleLayout}">
-- 
GitLab