mirror of
https://github.com/slawkens/myaac.git
synced 2025-10-14 01:34:55 +02:00
Save towns as plain PHP File in cache folder
+ Also load them on install + on reload items = better performance when in dev mode
This commit is contained in:
@@ -32,4 +32,12 @@ if ($reload) {
|
||||
else {
|
||||
error(Weapons::getError());
|
||||
}
|
||||
|
||||
$towns_start_time = microtime(true);
|
||||
if (Towns::save()) {
|
||||
success('Successfully loaded towns (in ' . round(microtime(true) - $towns_start_time, 4) . ' seconds).');
|
||||
}
|
||||
else {
|
||||
error('Error: No towns found.');
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user