From 139058cf804c24234b088909ce5c03e2df9ec0dc Mon Sep 17 00:00:00 2001
From: Cyperghost
Date: Thu, 21 Mar 2024 10:40:28 +0100
Subject: [PATCH] Add further variables to the language variables
---
...eportModerationQueueUserNotificationEvent.class.php | 10 ++++++++++
wcfsetup/install/lang/de.xml | 6 +++---
wcfsetup/install/lang/en.xml | 6 +++---
3 files changed, 16 insertions(+), 6 deletions(-)
diff --git a/wcfsetup/install/files/lib/system/user/notification/event/ReportModerationQueueUserNotificationEvent.class.php b/wcfsetup/install/files/lib/system/user/notification/event/ReportModerationQueueUserNotificationEvent.class.php
index 4ff92bf187..a2864a016c 100644
--- a/wcfsetup/install/files/lib/system/user/notification/event/ReportModerationQueueUserNotificationEvent.class.php
+++ b/wcfsetup/install/files/lib/system/user/notification/event/ReportModerationQueueUserNotificationEvent.class.php
@@ -43,6 +43,11 @@ final class ReportModerationQueueUserNotificationEvent extends AbstractUserNotif
'author' => $this->author,
'notification' => $this->notification,
'moderationQueue' => $this->getViewableModerationQueue(),
+ 'title' => $this->getViewableModerationQueue()->getTitle(),
+ 'objectLink' => $this->getViewableModerationQueue()->getLink(),
+ 'typeName' => $this->getLanguage()->getDynamicVariable(
+ "wcf.moderation.type." . $this->getViewableModerationQueue()->getObjectTypeName()
+ )
]
);
}
@@ -63,6 +68,11 @@ final class ReportModerationQueueUserNotificationEvent extends AbstractUserNotif
'author' => $this->author,
'notification' => $this->notification,
'moderationQueue' => $this->getViewableModerationQueue(),
+ 'title' => $this->getViewableModerationQueue()->getTitle(),
+ 'objectLink' => $this->getViewableModerationQueue()->getLink(),
+ 'typeName' => $this->getLanguage()->getDynamicVariable(
+ "wcf.moderation.type." . $this->getViewableModerationQueue()->getObjectTypeName()
+ )
],
];
}
diff --git a/wcfsetup/install/lang/de.xml b/wcfsetup/install/lang/de.xml
index b704ead3b3..9b80b72def 100644
--- a/wcfsetup/install/lang/de.xml
+++ b/wcfsetup/install/lang/de.xml
@@ -4390,9 +4390,9 @@ Dateianhänge:
- - userID}{$author}{else}Ein Gast{/if} hat {$moderationQueue->getTitle()}({lang}wcf.moderation.type.{@$moderationQueue->getObjectTypeName()}{/lang}) gemeldet.]]>
- - userID}{$author}{else}Ein Gast{/if} hat {$moderationQueue->getTitle()} ({lang}wcf.moderation.type.{@$moderationQueue->getObjectTypeName()}{/lang}) gemeldet [URL:{$moderationQueue->getLink()}].]]>
- - {if $author->userID}{$author}{else}Ein Gast{/if} hat {$moderationQueue->getTitle()} ({lang}wcf.moderation.type.{@$moderationQueue->getObjectTypeName()}{/lang}) gemeldet.
]]>
+ - userID}{$author}{else}Ein Gast{/if} hat {$title}({$typeName}) gemeldet.]]>
+ - userID}{$author}{else}Ein Gast{/if} hat {$title} ({$typeName}) gemeldet [URL:{$objectLink}].]]>
+ - {if $author->userID}{$author}{else}Ein Gast{/if} hat {$title} ({$typeName}) gemeldet.]]>
diff --git a/wcfsetup/install/lang/en.xml b/wcfsetup/install/lang/en.xml
index 895fb3de79..90135426c9 100644
--- a/wcfsetup/install/lang/en.xml
+++ b/wcfsetup/install/lang/en.xml
@@ -4342,9 +4342,9 @@ Attachments:
- - userID}{$author}{else}A guest{/if} has reported {$moderationQueue->getTitle()}({lang}wcf.moderation.type.{@$moderationQueue->getObjectTypeName()}{/lang}).]]>
- - userID}{$author}{else}A guest{/if} has reported {$moderationQueue->getTitle()} ({lang}wcf.moderation.type.{@$moderationQueue->getObjectTypeName()}{/lang}) [URL:{$moderationQueue->getLink()}].]]>
- - {if $author->userID}{$author}{else}A guest{/if} has reported {$moderationQueue->getTitle()} ({lang}wcf.moderation.type.{@$moderationQueue->getObjectTypeName()}{/lang}):]]>
+ - userID}{$author}{else}A guest{/if} has reported {$title}({$typeName}).]]>
+ - userID}{$author}{else}A guest{/if} has reported {$title} ({$typeName}) [URL:{$objectLink}].]]>
+ - {if $author->userID}{$author}{else}A guest{/if} has reported {$title} ({$typeName}):]]>
--
2.20.1