Fix smiley tab if default category is empty
authorMatthias Schmidt <gravatronics@live.com>
Sun, 1 Mar 2015 18:01:18 +0000 (19:01 +0100)
committerMatthias Schmidt <gravatronics@live.com>
Sun, 1 Mar 2015 18:01:18 +0000 (19:01 +0100)
com.woltlab.wcf/templates/messageFormSmilies.tpl

index 114b9fc960800657fab6bb0bcecab5080e1d5444..1490dee605e04995f2637a3a12444638985c7933 100644 (file)
@@ -9,7 +9,8 @@
 
 <div class="container containerPadding{if $__tabCount} messageTabMenu{/if}" data-preselect="true" data-collapsible="false" id="smilies-{if $wysiwygSelector|isset}{$wysiwygSelector}{else}text{/if}">
        {capture assign=__defaultSmilies}
-               {include file='__messageFormSmilies' smilies=$__wcf->getSmileyCache()->getCategorySmilies()}
+               {assign var='__firstSmileyCategory' value=$smileyCategories|reset}
+               {include file='__messageFormSmilies' smilies=$__wcf->getSmileyCache()->getCategorySmilies($__firstSmileyCategory->categoryID)}
        {/capture}
        
        {if $__tabCount > 1}