Copying a style did not reset the style cache
authorAlexander Ebert <ebert@woltlab.com>
Mon, 2 Mar 2015 14:20:42 +0000 (15:20 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Mon, 2 Mar 2015 14:20:42 +0000 (15:20 +0100)
wcfsetup/install/files/lib/data/style/StyleAction.class.php

index 21c5a0ed3aac4b86f8ac5cce5bc947719e1e6dd5..8e120a3307b2dd853d958dee4958da412a4fc32a 100644 (file)
@@ -2,6 +2,7 @@
 namespace wcf\data\style;
 use wcf\data\AbstractDatabaseObjectAction;
 use wcf\data\IToggleAction;
+use wcf\system\cache\builder\StyleCacheBuilder;
 use wcf\system\exception\IllegalLinkException;
 use wcf\system\exception\PermissionDeniedException;
 use wcf\system\exception\SystemException;
@@ -510,6 +511,8 @@ class StyleAction extends AbstractDatabaseObjectAction implements IToggleAction
                        }
                }
                
+               StyleCacheBuilder::getInstance()->reset();
+               
                return array(
                        'redirectURL' => LinkHandler::getInstance()->getLink('StyleEdit', array('id' => $newStyle->styleID))
                );