Skip to content

Commit 7dafdda

Browse files
committed
bug symfony#18271 [FileSystem] Google app engine filesystem (swordbeta)
This PR was submitted for the master branch but it was merged into the 2.8 branch instead (closes symfony#18271). Discussion ---------- [FileSystem] Google app engine filesystem | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | symfony#17922 | License | MIT | Doc PR | - Commits ------- 06d8697 [FileSystem] Add support for Google App Engine.
2 parents 6376ea2 + 06d8697 commit 7dafdda

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Symfony/Component/Filesystem/Filesystem.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -486,13 +486,13 @@ public function tempnam($dir, $prefix)
486486
{
487487
list($scheme, $hierarchy) = $this->getSchemeAndHierarchy($dir);
488488

489-
// If no scheme or scheme is "file" create temp file in local filesystem
490-
if (null === $scheme || 'file' === $scheme) {
489+
// If no scheme or scheme is "file" or "gs" create temp file in local filesystem
490+
if (null === $scheme || 'file' === $scheme || 'gs' === $scheme) {
491491
$tmpFile = tempnam($hierarchy, $prefix);
492492

493493
// If tempnam failed or no scheme return the filename otherwise prepend the scheme
494494
if (false !== $tmpFile) {
495-
if (null !== $scheme) {
495+
if (null !== $scheme && 'gs' !== $scheme) {
496496
return $scheme.'://'.$tmpFile;
497497
}
498498

0 commit comments

Comments
 (0)