Skip to content

Commit 5cf603c

Browse files
Merge branch '4.4'
* 4.4: [OptionsResolve] Revert change in tests for a not-merged change in code [HttpClient] fix handling of 3xx with no Location header - ignore Content-Length when no body is expected [Workflow] Made the configuration more robust for the 'property' key [Security/Core] make NativePasswordEncoder use sodium to validate passwords when possible [FrameworkBundle] make SodiumVault report bad decryption key accurately cs fix [Security] Allow to set a fixed algorithm [Security/Core] make encodedLength computation more generic [Security/Core] add fast path when encoded password cannot match anything #30432 fix an error message fix paths to detect code owners [HttpClient] ignore the body of responses to HEAD requests [Validator] Ensure numeric subpaths do not cause errors on PHP 7.4 [SecurityBundle] Fix wrong assertion Remove unused local variables in tests [Yaml][Parser] Remove the getLastLineNumberBeforeDeprecation() internal unused method Make sure to collect child forms created on *_SET_DATA events [WebProfilerBundle] Improve display in Email panel for dark theme do not render errors for checkboxes twice
2 parents b20987e + 0bd01ca commit 5cf603c

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

Constraints/FileValidator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ public function validate($value, Constraint $constraint)
6161
$binaryFormat = null === $constraint->binaryFormat ? true : $constraint->binaryFormat;
6262
}
6363

64-
list($sizeAsString, $limitAsString, $suffix) = $this->factorizeSizes(0, $limitInBytes, $binaryFormat);
64+
list(, $limitAsString, $suffix) = $this->factorizeSizes(0, $limitInBytes, $binaryFormat);
6565
$this->context->buildViolation($constraint->uploadIniSizeErrorMessage)
6666
->setParameter('{{ limit }}', $limitAsString)
6767
->setParameter('{{ suffix }}', $suffix)

Tests/Constraints/FileValidatorTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -456,7 +456,7 @@ public function uploadedFileErrorProvider()
456456
$reflection = new \ReflectionClass(\get_class(new FileValidator()));
457457
$method = $reflection->getMethod('factorizeSizes');
458458
$method->setAccessible(true);
459-
list($sizeAsString, $limit, $suffix) = $method->invokeArgs(new FileValidator(), [0, UploadedFile::getMaxFilesize(), false]);
459+
list(, $limit, $suffix) = $method->invokeArgs(new FileValidator(), [0, UploadedFile::getMaxFilesize(), false]);
460460

461461
// it correctly parses the maxSize option and not only uses simple string comparison
462462
// 1000M should be bigger than the ini value

Tests/Util/PropertyPathTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ public function provideAppendPaths()
3232
['foo', 'bar', 'foo.bar', 'It append the subPath to the basePath'],
3333
['foo', '[bar]', 'foo[bar]', 'It does not include the dot separator if subPath uses the array notation'],
3434
['0', 'bar', '0.bar', 'Leading zeros are kept.'],
35+
['0', 1, '0.1', 'Numeric subpaths do not cause PHP 7.4 errors.'],
3536
];
3637
}
3738
}

0 commit comments

Comments
 (0)