Laravel 5.6 updates
Travis config update Removed HHVM script as Laravel no longer support HHVM after releasing 5.3
This commit is contained in:
@@ -19,7 +19,7 @@ namespace Symfony\Component\Finder\Iterator;
|
||||
*
|
||||
* @author Fabien Potencier <fabien@symfony.com>
|
||||
*/
|
||||
class CustomFilterIterator extends FilterIterator
|
||||
class CustomFilterIterator extends \FilterIterator
|
||||
{
|
||||
private $filters = array();
|
||||
|
||||
|
@@ -18,7 +18,7 @@ use Symfony\Component\Finder\Comparator\DateComparator;
|
||||
*
|
||||
* @author Fabien Potencier <fabien@symfony.com>
|
||||
*/
|
||||
class DateRangeFilterIterator extends FilterIterator
|
||||
class DateRangeFilterIterator extends \FilterIterator
|
||||
{
|
||||
private $comparators = array();
|
||||
|
||||
|
@@ -16,7 +16,7 @@ namespace Symfony\Component\Finder\Iterator;
|
||||
*
|
||||
* @author Fabien Potencier <fabien@symfony.com>
|
||||
*/
|
||||
class DepthRangeFilterIterator extends FilterIterator
|
||||
class DepthRangeFilterIterator extends \FilterIterator
|
||||
{
|
||||
private $minDepth = 0;
|
||||
|
||||
@@ -25,7 +25,7 @@ class DepthRangeFilterIterator extends FilterIterator
|
||||
* @param int $minDepth The min depth
|
||||
* @param int $maxDepth The max depth
|
||||
*/
|
||||
public function __construct(\RecursiveIteratorIterator $iterator, $minDepth = 0, $maxDepth = PHP_INT_MAX)
|
||||
public function __construct(\RecursiveIteratorIterator $iterator, int $minDepth = 0, int $maxDepth = PHP_INT_MAX)
|
||||
{
|
||||
$this->minDepth = $minDepth;
|
||||
$iterator->setMaxDepth(PHP_INT_MAX === $maxDepth ? -1 : $maxDepth);
|
||||
|
@@ -16,7 +16,7 @@ namespace Symfony\Component\Finder\Iterator;
|
||||
*
|
||||
* @author Fabien Potencier <fabien@symfony.com>
|
||||
*/
|
||||
class ExcludeDirectoryFilterIterator extends FilterIterator implements \RecursiveIterator
|
||||
class ExcludeDirectoryFilterIterator extends \FilterIterator implements \RecursiveIterator
|
||||
{
|
||||
private $iterator;
|
||||
private $isRecursive;
|
||||
|
@@ -16,7 +16,7 @@ namespace Symfony\Component\Finder\Iterator;
|
||||
*
|
||||
* @author Fabien Potencier <fabien@symfony.com>
|
||||
*/
|
||||
class FileTypeFilterIterator extends FilterIterator
|
||||
class FileTypeFilterIterator extends \FilterIterator
|
||||
{
|
||||
const ONLY_FILES = 1;
|
||||
const ONLY_DIRECTORIES = 2;
|
||||
@@ -27,7 +27,7 @@ class FileTypeFilterIterator extends FilterIterator
|
||||
* @param \Iterator $iterator The Iterator to filter
|
||||
* @param int $mode The mode (self::ONLY_FILES or self::ONLY_DIRECTORIES)
|
||||
*/
|
||||
public function __construct(\Iterator $iterator, $mode)
|
||||
public function __construct(\Iterator $iterator, int $mode)
|
||||
{
|
||||
$this->mode = $mode;
|
||||
|
||||
|
@@ -1,60 +0,0 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
* This file is part of the Symfony package.
|
||||
*
|
||||
* (c) Fabien Potencier <fabien@symfony.com>
|
||||
*
|
||||
* For the full copyright and license information, please view the LICENSE
|
||||
* file that was distributed with this source code.
|
||||
*/
|
||||
|
||||
namespace Symfony\Component\Finder\Iterator;
|
||||
|
||||
/**
|
||||
* This iterator just overrides the rewind method in order to correct a PHP bug,
|
||||
* which existed before version 5.5.23/5.6.7.
|
||||
*
|
||||
* @see https://bugs.php.net/68557
|
||||
*
|
||||
* @author Alex Bogomazov
|
||||
*
|
||||
* @deprecated since 3.4, to be removed in 4.0.
|
||||
*/
|
||||
abstract class FilterIterator extends \FilterIterator
|
||||
{
|
||||
/**
|
||||
* This is a workaround for the problem with \FilterIterator leaving inner \FilesystemIterator in wrong state after
|
||||
* rewind in some cases.
|
||||
*
|
||||
* @see FilterIterator::rewind()
|
||||
*/
|
||||
public function rewind()
|
||||
{
|
||||
if (\PHP_VERSION_ID > 50607 || (\PHP_VERSION_ID > 50523 && \PHP_VERSION_ID < 50600)) {
|
||||
parent::rewind();
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
$iterator = $this;
|
||||
while ($iterator instanceof \OuterIterator) {
|
||||
$innerIterator = $iterator->getInnerIterator();
|
||||
|
||||
if ($innerIterator instanceof RecursiveDirectoryIterator) {
|
||||
// this condition is necessary for iterators to work properly with non-local filesystems like ftp
|
||||
if ($innerIterator->isRewindable()) {
|
||||
$innerIterator->next();
|
||||
$innerIterator->rewind();
|
||||
}
|
||||
} elseif ($innerIterator instanceof \FilesystemIterator) {
|
||||
$innerIterator->next();
|
||||
$innerIterator->rewind();
|
||||
}
|
||||
|
||||
$iterator = $innerIterator;
|
||||
}
|
||||
|
||||
parent::rewind();
|
||||
}
|
||||
}
|
@@ -16,7 +16,7 @@ namespace Symfony\Component\Finder\Iterator;
|
||||
*
|
||||
* @author Fabien Potencier <fabien@symfony.com>
|
||||
*/
|
||||
abstract class MultiplePcreFilterIterator extends FilterIterator
|
||||
abstract class MultiplePcreFilterIterator extends \FilterIterator
|
||||
{
|
||||
protected $matchRegexps = array();
|
||||
protected $noMatchRegexps = array();
|
||||
|
@@ -37,13 +37,9 @@ class RecursiveDirectoryIterator extends \RecursiveDirectoryIterator
|
||||
private $directorySeparator = '/';
|
||||
|
||||
/**
|
||||
* @param string $path
|
||||
* @param int $flags
|
||||
* @param bool $ignoreUnreadableDirs
|
||||
*
|
||||
* @throws \RuntimeException
|
||||
*/
|
||||
public function __construct($path, $flags, $ignoreUnreadableDirs = false)
|
||||
public function __construct(string $path, int $flags, bool $ignoreUnreadableDirs = false)
|
||||
{
|
||||
if ($flags & (self::CURRENT_AS_PATHNAME | self::CURRENT_AS_SELF)) {
|
||||
throw new \RuntimeException('This iterator only support returning current as fileinfo.');
|
||||
@@ -116,11 +112,6 @@ class RecursiveDirectoryIterator extends \RecursiveDirectoryIterator
|
||||
return;
|
||||
}
|
||||
|
||||
// @see https://bugs.php.net/68557
|
||||
if (\PHP_VERSION_ID < 50523 || \PHP_VERSION_ID >= 50600 && \PHP_VERSION_ID < 50607) {
|
||||
parent::next();
|
||||
}
|
||||
|
||||
parent::rewind();
|
||||
}
|
||||
|
||||
@@ -135,11 +126,6 @@ class RecursiveDirectoryIterator extends \RecursiveDirectoryIterator
|
||||
return $this->rewindable;
|
||||
}
|
||||
|
||||
// workaround for an HHVM bug, should be removed when https://github.com/facebook/hhvm/issues/7281 is fixed
|
||||
if ('' === $this->getPath()) {
|
||||
return $this->rewindable = false;
|
||||
}
|
||||
|
||||
if (false !== $stream = @opendir($this->getPath())) {
|
||||
$infos = stream_get_meta_data($stream);
|
||||
closedir($stream);
|
||||
|
@@ -18,7 +18,7 @@ use Symfony\Component\Finder\Comparator\NumberComparator;
|
||||
*
|
||||
* @author Fabien Potencier <fabien@symfony.com>
|
||||
*/
|
||||
class SizeRangeFilterIterator extends FilterIterator
|
||||
class SizeRangeFilterIterator extends \FilterIterator
|
||||
{
|
||||
private $comparators = array();
|
||||
|
||||
|
Reference in New Issue
Block a user