Deleting a smiley category did not reset the cache
authorAlexander Ebert <ebert@woltlab.com>
Tue, 3 Mar 2015 12:33:39 +0000 (13:33 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Tue, 3 Mar 2015 12:33:39 +0000 (13:33 +0100)
wcfsetup/install/files/lib/system/category/SmileyCategoryType.class.php

index 07b6ebd38b783d698d67a22ed06bd5820a6f7f92..73c7f14dad84fcc9e53a83207b256bbf143f7f85 100644 (file)
@@ -1,5 +1,7 @@
 <?php
 namespace wcf\system\category;
+use wcf\data\category\CategoryEditor;
+use wcf\system\cache\builder\SmileyCacheBuilder;
 use wcf\system\category\AbstractCategoryType;
 use wcf\system\WCF;
 
@@ -29,6 +31,13 @@ class SmileyCategoryType extends AbstractCategoryType {
         */
        protected $maximumNestingLevel = 0;
        
+       /**
+        * @see \wcf\system\category\ICategoryType::afterDeletion()
+        */
+       public function afterDeletion(CategoryEditor $categoryEditor) {
+               SmileyCacheBuilder::getInstance()->reset();
+       }
+       
        /**
         * @see \wcf\system\category\ICategoryType::canAddCategory()
         */