Skip to content
This repository has been archived by the owner on Jan 29, 2020. It is now read-only.

Commit

Permalink
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 77 deletions.
17 changes: 12 additions & 5 deletions src/Storage/Adapter/FilesystemIterator.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ class FilesystemIterator implements IteratorInterface
{

/**
* The apc storage instance
* The Filesystem storage instance
*
* @var Apc
* @var Filesystem
*/
protected $storage;

Expand Down Expand Up @@ -89,7 +89,7 @@ public function getMode()
* Set iterator mode
*
* @param int $mode
* @return ApcIterator Fluent interface
* @return FilesystemIterator Fluent interface
*/
public function setMode($mode)
{
Expand Down Expand Up @@ -164,10 +164,17 @@ public function valid()
/**
* Rewind the Iterator to the first element.
*
* @return void
* @return bool false if the operation failed.
*/
public function rewind()
{
return $this->globIterator->rewind();
try {
return $this->globIterator->rewind();
} catch (\LogicException $e) {
// @link https://bugs.php.net/bug.php?id=55701
// GlobIterator throws LogicException with message
// 'The parent constructor was not called: the object is in an invalid state'
return false;
}
}
}
30 changes: 0 additions & 30 deletions test/TestAsset/DummyPattern.php

This file was deleted.

17 changes: 0 additions & 17 deletions test/TestAsset/DummyStorageAdapter.php

This file was deleted.

25 changes: 0 additions & 25 deletions test/TestAsset/DummyStoragePlugin.php

This file was deleted.

0 comments on commit 8ec947a

Please sign in to comment.