mirror of
https://github.com/slawkens/myaac.git
synced 2025-10-17 03:03:26 +02:00
* better error handling for monsters and spells loader
* check if file exist before loading * save errors to system/logs/error.log
This commit is contained in:
@@ -16,7 +16,9 @@ $canEdit = hasFlag(FLAG_CONTENT_SPELLS) || admin();
|
||||
if(isset($_POST['reload_spells']) && $canEdit)
|
||||
{
|
||||
require LIBS . 'spells.php';
|
||||
Spells::loadFromXML(true);
|
||||
if(!Spells::loadFromXML(true)) {
|
||||
error(Spells::getLastError());
|
||||
}
|
||||
}
|
||||
|
||||
if($canEdit)
|
||||
|
Reference in New Issue
Block a user