Fix check of $attachmentHandler object in messageFormTabs.tpl
authorMatthias Schmidt <gravatronics@live.com>
Mon, 25 Aug 2014 16:17:37 +0000 (18:17 +0200)
committerMatthias Schmidt <gravatronics@live.com>
Mon, 25 Aug 2014 16:17:37 +0000 (18:17 +0200)
com.woltlab.wcf/templates/messageFormTabs.tpl

index 55c915680d17309fa984c819a094b6edc8e7064d..c77c8ff76766c6713c69dc6ed1bb1c8f354bdbb3 100644 (file)
@@ -2,7 +2,7 @@
        <nav class="messageTabMenuNavigation jsOnly">
                <ul>
                        {if MODULE_SMILEY && $__wcf->getSession()->getPermission($permissionCanUseSmilies) && $smileyCategories|count}<li data-name="smilies"><a>{lang}wcf.message.smilies{/lang}</a></li>{/if}
-                       {if MODULE_ATTACHMENT && $attachmentHandler !== null && $attachmentHandler->canUpload()}<li data-name="attachments"><a>{lang}wcf.attachment.attachments{/lang}</a></li>{/if}
+                       {if MODULE_ATTACHMENT && !$attachmentHandler|empty && $attachmentHandler->canUpload()}<li data-name="attachments"><a>{lang}wcf.attachment.attachments{/lang}</a></li>{/if}
                        <li data-name="settings"><a>{lang}wcf.message.settings{/lang}</a></li>
                        {if $__showPoll|isset && $__showPoll}<li data-name="poll"><a>{lang}wcf.poll.management{/lang}</a></li>{/if}
                        {event name='tabMenuTabs'}
@@ -10,7 +10,7 @@
        </nav>
        
        {if MODULE_SMILEY && $__wcf->getSession()->getPermission($permissionCanUseSmilies) && $smileyCategories|count}{include file='messageFormSmilies'}{/if}
-       {if MODULE_ATTACHMENT && $attachmentHandler !== null && $attachmentHandler->canUpload()}{include file='messageFormAttachments'}{/if}
+       {if MODULE_ATTACHMENT && !$attachmentHandler|empty && $attachmentHandler->canUpload()}{include file='messageFormAttachments'}{/if}
        
        {include file='messageFormSettings'}
        {include file='__messageFormPoll'}
@@ -24,4 +24,4 @@
                $('.messageTabMenu').messageTabMenu();
        });
        //]]>
-</script>
\ No newline at end of file
+</script>