aboutsummaryrefslogtreecommitdiffstats
path: root/include/plugin.php
diff options
context:
space:
mode:
authorM.Dent <dentm42@dm42.net>2018-04-07 23:01:18 -0400
committerM.Dent <dentm42@dm42.net>2018-04-07 23:01:18 -0400
commit35b4f0a863421fdfe27b6371516dc37805583317 (patch)
treec4822101f81df86430d8bd99b5c2ff04c7cbd003 /include/plugin.php
parent0fba1a777e155781a8c59c85c4443dc4f56f165d (diff)
downloadvolse-hubzilla-35b4f0a863421fdfe27b6371516dc37805583317.tar.gz
volse-hubzilla-35b4f0a863421fdfe27b6371516dc37805583317.tar.bz2
volse-hubzilla-35b4f0a863421fdfe27b6371516dc37805583317.zip
Add class for Exceptions
Diffstat (limited to 'include/plugin.php')
-rwxr-xr-xinclude/plugin.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/include/plugin.php b/include/plugin.php
index 29d24b410..2ef33e6fa 100755
--- a/include/plugin.php
+++ b/include/plugin.php
@@ -37,7 +37,7 @@ function unload_plugin($plugin){
$func = $plugin . '_unload';
try {
$func();
- } catch ($e) {
+ } catch (Exception $e) {
handleerrors_plugin($plugin,"Unable to unload.",$e->getMessage());
}
}
@@ -62,7 +62,7 @@ function uninstall_plugin($plugin) {
$func = $plugin . '_uninstall';
try {
$func();
- } catch ($e) {
+ } catch (Exception $e) {
handleerrors_plugin($plugin,"Unable to uninstall.","Unable to run _uninstall : ".$e->getMessage());
}
}
@@ -92,7 +92,7 @@ function install_plugin($plugin) {
$func = $plugin . '_install';
try {
$func();
- } catch ($e) {
+ } catch (Exception $e) {
handleerrors_plugin($plugin,"Install failed.","Install failed : ".$e->getMessage());
return;
}
@@ -127,7 +127,7 @@ function load_plugin($plugin) {
$func = $plugin . '_load';
try {
$func();
- } catch ($e) {
+ } catch (Exception $e) {
handleerrors_plugin($plugin,"Unable to load.","FAILED loading : ".$e->getMessage());
return;
}
@@ -198,7 +198,7 @@ function reload_plugins() {
$func = $pl . '_unload';
try {
$func();
- } catch ($e) {
+ } catch (Exception $e) {
handleerrors_plugin($plugin,"","UNLOAD FAILED (uninstalling) : ".$e->getMessage(),true);
continue;
}
@@ -207,7 +207,7 @@ function reload_plugins() {
$func = $pl . '_load';
try {
$func();
- } catch ($e) {
+ } catch (Exception $e) {
handleerrors_plugin($plugin,"","LOAD FAILED (uninstalling): ".$e->getMessage(),true);
continue;
}