mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-07-23 19:34:15 +00:00
Merge pull request #1818 from 64FF00/master
Added getExecutor() and setExecutor() method to PluginCommand
This commit is contained in:
commit
7ddfd4394d
@ -61,6 +61,17 @@ class PluginCommand extends Command implements PluginIdentifiableCommand{
|
|||||||
|
|
||||||
return $success;
|
return $success;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function getExecutor(){
|
||||||
|
return $this->executor;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param CommandExecutor $executor
|
||||||
|
*/
|
||||||
|
public function setExecutor(CommandExecutor $executor){
|
||||||
|
$this->executor = ($executor != null) ? $executor : $this->owningPlugin;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return Plugin
|
* @return Plugin
|
||||||
@ -68,4 +79,4 @@ class PluginCommand extends Command implements PluginIdentifiableCommand{
|
|||||||
public function getPlugin(){
|
public function getPlugin(){
|
||||||
return $this->owningPlugin;
|
return $this->owningPlugin;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user