mirror of
https://github.com/processwire/processwire.git
synced 2025-08-08 07:47:00 +02:00
Minor tweaks
This commit is contained in:
@@ -291,8 +291,9 @@ class Pages extends Wire {
|
||||
$debug = $this->debug;
|
||||
if($debug) $this->debug(false);
|
||||
$options['lazy'] = true;
|
||||
$options['caller'] = 'pages.findMany';
|
||||
if(!isset($options['cache'])) $options['cache'] = false;
|
||||
$matches = $this->loader->find($selector, $options);
|
||||
$matches = $this->find($selector, $options);
|
||||
if($debug) $this->debug($debug);
|
||||
return $matches;
|
||||
}
|
||||
|
@@ -244,11 +244,13 @@ class PagesLoader extends Wire {
|
||||
$pages->finderOptions($options);
|
||||
$pages->setDuplicateChecking(false);
|
||||
$loadPages = false;
|
||||
$cachePages = false;
|
||||
$template = null;
|
||||
|
||||
foreach($pagesIDs as $id) {
|
||||
$page = $this->pages->newPage();
|
||||
$page->_lazy($id);
|
||||
$page->loaderCache = false;
|
||||
$pages->add($page);
|
||||
}
|
||||
|
||||
@@ -661,6 +663,7 @@ class PagesLoader extends Wire {
|
||||
}
|
||||
unset($row['templates_id']);
|
||||
foreach($row as $key => $value) $page->set($key, $value);
|
||||
if($options['cache'] === false) $page->loaderCache = false;
|
||||
$page->instanceID = ++$instanceID;
|
||||
$page->setIsLoaded(true);
|
||||
$page->setIsNew(false);
|
||||
|
Reference in New Issue
Block a user