mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-22 00:33:59 +00:00
More foolproof region file extension check
This commit is contained in:
parent
3848f6f39c
commit
3672d60bf4
@ -211,7 +211,7 @@ class McRegion extends BaseLevelProvider{
|
||||
if($isValid){
|
||||
$files = glob($path . "/region/*.mc*");
|
||||
foreach($files as $f){
|
||||
if(strpos($f, "." . static::REGION_FILE_EXTENSION) === false){
|
||||
if(substr($f, strrpos($f, ".") + 1) !== static::REGION_FILE_EXTENSION){
|
||||
$isValid = false;
|
||||
break;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user