mirror of
https://github.com/processwire/processwire.git
synced 2025-08-17 04:04:13 +02:00
Fix php notice in new PageimageVariations.php class
This commit is contained in:
@@ -316,7 +316,7 @@ class PageimageVariations extends Wire implements \IteratorAggregate, \Countable
|
|||||||
$infos = array();
|
$infos = array();
|
||||||
$count = 0;
|
$count = 0;
|
||||||
|
|
||||||
if(!$options['info'] && $options['count']) {
|
if(!$options['info'] && !$options['count']) {
|
||||||
$variations = $this->wire(new Pageimages($this->pagefiles->page));
|
$variations = $this->wire(new Pageimages($this->pagefiles->page));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -395,7 +395,7 @@ class PageimageVariations extends Wire implements \IteratorAggregate, \Countable
|
|||||||
$pageimage->setOriginal($this->pageimage);
|
$pageimage->setOriginal($this->pageimage);
|
||||||
if($options['verbose'] === 1) {
|
if($options['verbose'] === 1) {
|
||||||
$info['pageimage'] = $pageimage;
|
$info['pageimage'] = $pageimage;
|
||||||
} else {
|
} else if($variations) {
|
||||||
$variations->add($pageimage);
|
$variations->add($pageimage);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user