mirror of
https://github.com/maximebf/php-debugbar.git
synced 2025-07-28 04:00:43 +02:00
Skip loading offset on empty filter
This commit is contained in:
@@ -67,7 +67,13 @@ class FileStorage implements StorageInterface
|
|||||||
|
|
||||||
//Load the metadata and filter the results.
|
//Load the metadata and filter the results.
|
||||||
$results = array();
|
$results = array();
|
||||||
|
$i = 0;
|
||||||
foreach ($files as $file) {
|
foreach ($files as $file) {
|
||||||
|
//When filter is empty, skip loading the offset
|
||||||
|
if($i++ < $offset && empty($filters)){
|
||||||
|
$results[] = null;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$data = $this->get($file['id']);
|
$data = $this->get($file['id']);
|
||||||
$meta = $data['__meta'];
|
$meta = $data['__meta'];
|
||||||
unset($data);
|
unset($data);
|
||||||
|
Reference in New Issue
Block a user