mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-04 00:55:14 +00:00
Added a getEntry() to BanList (#1830)
This commit is contained in:
committed by
Dylan K. Taylor
parent
4f8e4f0522
commit
1b4b832c8c
@ -58,6 +58,17 @@ class BanList{
|
|||||||
$this->enabled = $flag;
|
$this->enabled = $flag;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param string $name
|
||||||
|
*
|
||||||
|
* @return BanEntry|null
|
||||||
|
*/
|
||||||
|
public function getEntry(string $name) : ?BanEntry{
|
||||||
|
$this->removeExpired();
|
||||||
|
|
||||||
|
return $this->list[strtolower($name)] ?? null;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return BanEntry[]
|
* @return BanEntry[]
|
||||||
*/
|
*/
|
||||||
|
Reference in New Issue
Block a user