summaryrefslogtreecommitdiffstats
path: root/lib/hook.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/hook.php')
-rw-r--r--lib/hook.php17
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/hook.php b/lib/hook.php
index 83a16106bf0..b53755310e0 100644
--- a/lib/hook.php
+++ b/lib/hook.php
@@ -65,5 +65,22 @@ class OC_Hook{
// return true
return true;
}
+
+ /**
+ * clear hooks
+ * @param string signalclass
+ * @param string signalname
+ */
+ static public function clear($signalclass='', $signalname=''){
+ if($signalclass){
+ if($signalname){
+ self::$registered[$signalclass][$signalname]=array();
+ }else{
+ self::$registered[$signalclass]=array();
+ }
+ }else{
+ self::$registered=array();
+ }
+ }
}