Skip to content

Commit 548ebbe

Browse files
Merge branch '5.1' into 5.2
* 5.1: µCS fix CS fix CS fix [travis] use PHP 8.0 to patch return types and run deps=low Add me as a Notifier code owner Update sl_SI translations Don't trigger deprecation for deprecated aliases pointing to deprecated definitions [HttpFoundation] use atomic writes in MockFileSessionStorage Make EmailMessage & SmsMessage transport nullable remove unused argument [DI] fix param annotation [Config] Add \Symfony\Component\Config\Loader::load() return type Simplify PHP CS Fixer config Rename normalize param
2 parents 76a2bbb + 193070b commit 548ebbe

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

Dumper/AbstractDumper.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public function setOutput($output)
7070
$this->lineDumper = $output;
7171
} else {
7272
if (\is_string($output)) {
73-
$output = fopen($output, 'wb');
73+
$output = fopen($output, 'w');
7474
}
7575
$this->outputStream = $output;
7676
$this->lineDumper = [$this, 'echoLine'];
@@ -128,7 +128,7 @@ public function dump(Data $data, $output = null)
128128
}
129129

130130
if ($returnDump = true === $output) {
131-
$output = fopen('php://memory', 'r+b');
131+
$output = fopen('php://memory', 'r+');
132132
}
133133
if ($output) {
134134
$prevOutput = $this->setOutput($output);

Dumper/CliDumper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -538,7 +538,7 @@ protected function supportsColors()
538538
}
539539

540540
$h = stream_get_meta_data($this->outputStream) + ['wrapper_type' => null];
541-
$h = 'Output' === $h['stream_type'] && 'PHP' === $h['wrapper_type'] ? fopen('php://stdout', 'wb') : $this->outputStream;
541+
$h = 'Output' === $h['stream_type'] && 'PHP' === $h['wrapper_type'] ? fopen('php://stdout', 'w') : $this->outputStream;
542542

543543
return static::$defaultColors = $this->hasColorSupport($h);
544544
}

Tests/Dumper/CliDumperTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ public function testFlags()
320320
*/
321321
public function testThrowingCaster()
322322
{
323-
$out = fopen('php://memory', 'r+b');
323+
$out = fopen('php://memory', 'r+');
324324

325325
require_once __DIR__.'/../Fixtures/Twig.php';
326326
$twig = new \__TwigTemplate_VarDumperFixture_u75a09(new Environment(new FilesystemLoader()));

Tests/Dumper/HtmlDumperTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ public function testCharset()
141141

142142
public function testAppend()
143143
{
144-
$out = fopen('php://memory', 'r+b');
144+
$out = fopen('php://memory', 'r+');
145145

146146
$dumper = new HtmlDumper();
147147
$dumper->setDumpHeader('<foo></foo>');

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
"ext-iconv": "*",
2525
"symfony/console": "^4.4|^5.0",
2626
"symfony/process": "^4.4|^5.0",
27-
"twig/twig": "^2.4|^3.0"
27+
"twig/twig": "^2.13|^3.0.4"
2828
},
2929
"conflict": {
3030
"phpunit/phpunit": "<5.4.3",

0 commit comments

Comments
 (0)