mirror of
https://github.com/adlawson/php-vfs.git
synced 2025-01-23 21:58:26 +00:00
Don't automatically mount on FileSystem factory
This is to maintain the same behaviour whether you use the factory or the builder.
This commit is contained in:
parent
3c4cecc423
commit
dcd516c4e7
@ -41,7 +41,7 @@ class FileSystem implements FileSystemInterface
|
|||||||
LoggerInterface $logger
|
LoggerInterface $logger
|
||||||
) {
|
) {
|
||||||
$this->wrapperClass = $wrapperClass;
|
$this->wrapperClass = $wrapperClass;
|
||||||
$this->scheme = $this->formatScheme($scheme);
|
$this->scheme = rtrim($scheme, ':/\\');
|
||||||
$this->walker = $walker;
|
$this->walker = $walker;
|
||||||
$this->logger = $logger;
|
$this->logger = $logger;
|
||||||
$this->factory = $factory;
|
$this->factory = $factory;
|
||||||
@ -58,10 +58,7 @@ class FileSystem implements FileSystemInterface
|
|||||||
{
|
{
|
||||||
$builder = new FileSystemBuilder($scheme);
|
$builder = new FileSystemBuilder($scheme);
|
||||||
|
|
||||||
$fs = $builder->build();
|
return $builder->build();
|
||||||
$fs->mount();
|
|
||||||
|
|
||||||
return $fs;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -139,13 +136,4 @@ class FileSystem implements FileSystemInterface
|
|||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* @param string $scheme
|
|
||||||
* @return string
|
|
||||||
*/
|
|
||||||
protected function formatScheme($scheme)
|
|
||||||
{
|
|
||||||
return rtrim($scheme, ':/\\');
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user