Added event after install/uninstall
authorAlexander Ebert <ebert@woltlab.com>
Fri, 5 Apr 2013 22:00:59 +0000 (00:00 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Fri, 5 Apr 2013 22:00:59 +0000 (00:00 +0200)
Fixes #1192

wcfsetup/install/files/lib/system/package/PackageInstallationDispatcher.class.php
wcfsetup/install/files/lib/system/package/PackageUninstallationDispatcher.class.php

index 36334f05d1c0e42bc897d0e50acdf0535671b8a9..09cc75e676172d0f383ac580080ca640c94aa424 100644 (file)
@@ -1,7 +1,5 @@
 <?php
 namespace wcf\system\package;
-use wcf\system\user\storage\UserStorageHandler;
-
 use wcf\data\application\Application;
 use wcf\data\application\ApplicationEditor;
 use wcf\data\language\category\LanguageCategory;
@@ -18,6 +16,7 @@ use wcf\system\cache\builder\TemplateListenerCodeCacheBuilder;
 use wcf\system\cache\CacheHandler;
 use wcf\system\database\statement\PreparedStatement;
 use wcf\system\database\util\PreparedStatementConditionBuilder;
+use wcf\system\event\EventHandler;
 use wcf\system\exception\SystemException;
 use wcf\system\form\container\GroupFormElementContainer;
 use wcf\system\form\container\MultipleSelectionFormElementContainer;
@@ -32,6 +31,7 @@ use wcf\system\request\LinkHandler;
 use wcf\system\request\RouteHandler;
 use wcf\system\setup\Installer;
 use wcf\system\style\StyleHandler;
+use wcf\system\user\storage\UserStorageHandler;
 use wcf\system\version\VersionHandler;
 use wcf\system\WCF;
 use wcf\util\FileUtil;
@@ -179,6 +179,8 @@ class PackageInstallationDispatcher {
                        
                        // reset user storage
                        UserStorageHandler::getInstance()->resetAll();
+                       
+                       EventHandler::getInstance()->fireAction($this, 'postInstall');
                }       
                
                if ($this->requireRestructureVersionTables) {
index 4a74f07d4c8091717584251eda6647179c7e01b1..a241b34d2be3afdabfcff993c6eb10f3fa743804 100644 (file)
@@ -7,6 +7,7 @@ use wcf\data\package\PackageEditor;
 use wcf\system\application\ApplicationHandler;
 use wcf\system\cache\builder\PackageCacheBuilder;
 use wcf\system\cache\CacheHandler;
+use wcf\system\event\EventHandler;
 use wcf\system\exception\IllegalLinkException;
 use wcf\system\exception\SystemException;
 use wcf\system\language\LanguageFactory;
@@ -14,6 +15,7 @@ use wcf\system\package\plugin\ObjectTypePackageInstallationPlugin;
 use wcf\system\package\plugin\SQLPackageInstallationPlugin;
 use wcf\system\setup\Uninstaller;
 use wcf\system\style\StyleHandler;
+use wcf\system\user\storage\UserStorageHandler;
 use wcf\system\WCF;
 
 /**
@@ -87,6 +89,8 @@ class PackageUninstallationDispatcher extends PackageInstallationDispatcher {
                        
                        // reset user storage
                        UserStorageHandler::getInstance()->resetAll();
+                       
+                       EventHandler::getInstance()->fireAction($this, 'postUninstall');
                }
                
                if ($this->requireRestructureVersionTables) {