mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-21 08:17:34 +00:00
Ooops, ;)
This commit is contained in:
parent
5bdb61117f
commit
5057a3965e
@ -95,7 +95,7 @@ abstract class BaseEvent{
|
||||
static::$handlerPriority = array();
|
||||
}
|
||||
|
||||
public function register(callable $handler, $priority = EventPriority::NORMAL){
|
||||
public static function register(callable $handler, $priority = EventPriority::NORMAL){
|
||||
if($priority < EventPriority::MONITOR or $priority > EventPriority::LOWEST){
|
||||
return false;
|
||||
}
|
||||
@ -112,7 +112,7 @@ abstract class BaseEvent{
|
||||
}
|
||||
}
|
||||
|
||||
public function unregister(callable $handler, $priority = EventPriority::NORMAL){
|
||||
public static function unregister(callable $handler, $priority = EventPriority::NORMAL){
|
||||
$identifier = Utils::getCallableIdentifier($handler);
|
||||
if(isset(static::$handlers[$identifier])){
|
||||
if(isset(static::$handlerPriority[(int) $priority][$identifier])){
|
||||
|
Loading…
x
Reference in New Issue
Block a user