File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -461,7 +461,7 @@ private function initializeProductCollection()
461
461
// if the product is associated with any category
462
462
if ($ categories ->count ()) {
463
463
// show products from this category
464
- $ this ->setCategoryId (current ( $ categories ->getIterator ())->getId ());
464
+ $ this ->setCategoryId ($ categories ->getIterator ()-> current ( )->getId ());
465
465
}
466
466
}
467
467
Original file line number Diff line number Diff line change @@ -195,7 +195,7 @@ public function testGetIdentities()
195
195
196
196
$ this ->catCollectionMock ->expects ($ this ->once ())
197
197
->method ('getIterator ' )
198
- ->willReturn ([$ currentCategory ]);
198
+ ->willReturn (new \ ArrayIterator ( [$ currentCategory ]) );
199
199
200
200
$ this ->prodCollectionMock ->expects ($ this ->any ())
201
201
->method ('getIterator ' )
You can’t perform that action at this time.
0 commit comments