From 2abba2b79c4bbd4253ea92a2180ff129a3ff0050 Mon Sep 17 00:00:00 2001 From: Matthias Schmidt Date: Sun, 24 May 2020 16:07:29 +0200 Subject: [PATCH] Remove all references to MODULE_ATTACHMENT Close #3333 --- com.woltlab.wcf/acpMenu.xml | 1 - com.woltlab.wcf/option.xml | 1 - com.woltlab.wcf/templates/messageFormTabs.tpl | 8 ++++++-- com.woltlab.wcf/templates/messageFormTabsInline.tpl | 8 ++++++-- com.woltlab.wcf/userGroupOption.xml | 1 - wcfsetup/install/files/lib/form/MessageForm.class.php | 2 +- .../files/lib/system/message/QuickReplyManager.class.php | 2 +- wcfsetup/install/lang/de.xml | 1 - wcfsetup/install/lang/en.xml | 1 - 9 files changed, 14 insertions(+), 11 deletions(-) diff --git a/com.woltlab.wcf/acpMenu.xml b/com.woltlab.wcf/acpMenu.xml index 01befe972c..865da65e58 100644 --- a/com.woltlab.wcf/acpMenu.xml +++ b/com.woltlab.wcf/acpMenu.xml @@ -508,7 +508,6 @@ wcf\acp\page\AttachmentListPage wcf.acp.menu.link.attachment - module_attachment admin.attachment.canManageAttachment diff --git a/com.woltlab.wcf/option.xml b/com.woltlab.wcf/option.xml index e742a96e20..0b399cd8de 100644 --- a/com.woltlab.wcf/option.xml +++ b/com.woltlab.wcf/option.xml @@ -221,7 +221,6 @@ message - module_attachment message.attachment diff --git a/com.woltlab.wcf/templates/messageFormTabs.tpl b/com.woltlab.wcf/templates/messageFormTabs.tpl index 58901643d7..618d2bc649 100644 --- a/com.woltlab.wcf/templates/messageFormTabs.tpl +++ b/com.woltlab.wcf/templates/messageFormTabs.tpl @@ -5,7 +5,9 @@ {if MODULE_SMILEY && !$smileyCategories|empty}{include file='messageFormSmilies'}{/if} - {if MODULE_ATTACHMENT && !$attachmentHandler|empty && $attachmentHandler->canUpload()}{include file='messageFormAttachments'}{/if} + {if !$attachmentHandler|empty && $attachmentHandler->canUpload()} + {include file='messageFormAttachments'} + {/if} {if $__messageFormSettings}{@$__messageFormSettings}{/if} {include file='__messageFormPoll'} diff --git a/com.woltlab.wcf/templates/messageFormTabsInline.tpl b/com.woltlab.wcf/templates/messageFormTabsInline.tpl index 1211facae1..4e3b62250a 100644 --- a/com.woltlab.wcf/templates/messageFormTabsInline.tpl +++ b/com.woltlab.wcf/templates/messageFormTabsInline.tpl @@ -9,7 +9,9 @@ {if MODULE_SMILEY && !$smileyCategories|empty}{include file='messageFormSmilies'}{/if} - {if MODULE_ATTACHMENT && !$attachmentHandler|empty && $attachmentHandler->canUpload()}{include file='messageFormAttachments'}{/if} + {if !$attachmentHandler|empty && $attachmentHandler->canUpload()} + {include file='messageFormAttachments'} + {/if} {if $__messageFormSettingsInlineContent}{@$__messageFormSettingsInlineContent}{/if} diff --git a/com.woltlab.wcf/userGroupOption.xml b/com.woltlab.wcf/userGroupOption.xml index b90c6b7aa2..d99d4f700e 100644 --- a/com.woltlab.wcf/userGroupOption.xml +++ b/com.woltlab.wcf/userGroupOption.xml @@ -471,7 +471,6 @@ admin.content boolean 0 - module_attachment 1 1 diff --git a/wcfsetup/install/files/lib/form/MessageForm.class.php b/wcfsetup/install/files/lib/form/MessageForm.class.php index 4f4b376a73..cec8565874 100644 --- a/wcfsetup/install/files/lib/form/MessageForm.class.php +++ b/wcfsetup/install/files/lib/form/MessageForm.class.php @@ -270,7 +270,7 @@ abstract class MessageForm extends AbstractCaptchaForm { */ public function readData() { // get attachments - if (MODULE_ATTACHMENT && $this->attachmentObjectType) { + if ($this->attachmentObjectType) { $this->attachmentHandler = new AttachmentHandler($this->attachmentObjectType, $this->attachmentObjectID, $this->tmpHash, $this->attachmentParentObjectID); } diff --git a/wcfsetup/install/files/lib/system/message/QuickReplyManager.class.php b/wcfsetup/install/files/lib/system/message/QuickReplyManager.class.php index 0ba5658c1e..81c62ce460 100644 --- a/wcfsetup/install/files/lib/system/message/QuickReplyManager.class.php +++ b/wcfsetup/install/files/lib/system/message/QuickReplyManager.class.php @@ -211,7 +211,7 @@ class QuickReplyManager extends SingletonFactory { $parameters['data'] = array_merge($additionalFields, $parameters['data']); // attachment support - if (MODULE_ATTACHMENT && !empty($parameters['tmpHash']) && $object instanceof IAttachmentMessageQuickReplyAction) { + if (!empty($parameters['tmpHash']) && $object instanceof IAttachmentMessageQuickReplyAction) { $parameters['attachmentHandler'] = $object->getAttachmentHandler($this->container); } diff --git a/wcfsetup/install/lang/de.xml b/wcfsetup/install/lang/de.xml index e474d2f8bc..1fdcca215d 100644 --- a/wcfsetup/install/lang/de.xml +++ b/wcfsetup/install/lang/de.xml @@ -1406,7 +1406,6 @@ ACHTUNG: Die oben genannten Meldungen sind stark gekürzt. Sie können Details z - diff --git a/wcfsetup/install/lang/en.xml b/wcfsetup/install/lang/en.xml index edaa7ef198..c7d74daae1 100644 --- a/wcfsetup/install/lang/en.xml +++ b/wcfsetup/install/lang/en.xml @@ -1383,7 +1383,6 @@ ATTENTION: The messages listed above are greatly shortened. You can view details - -- 2.20.1