mirror of
https://github.com/processwire/processwire.git
synced 2025-08-07 07:16:51 +02:00
Add new $pages->cache()->hasCache($page_id) method
This commit is contained in:
@@ -91,6 +91,18 @@ class PagesLoaderCache extends Wire {
|
||||
return $page;
|
||||
}
|
||||
|
||||
/**
|
||||
* Is given page ID in the cache?
|
||||
*
|
||||
* @param int page ID
|
||||
* @return bool
|
||||
* @since 3.0.243
|
||||
*
|
||||
*/
|
||||
public function hasCache($id) {
|
||||
return isset($this->pageIdCache[$id]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Cache the given page.
|
||||
*
|
||||
|
Reference in New Issue
Block a user