mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/TemplateData
synced 2024-11-27 09:10:00 +00:00
Use explicit nullable type on parameter arguments (for PHP 8.4)
Implicitly marking parameter $... as nullable is deprecated in PHP 8.4. The explicit nullable type must be used instead. Bug: T376276 Change-Id: Ibd54adb359d2993663db6453e83245d1335ccf63
This commit is contained in:
parent
b7d811c613
commit
38e1d50414
|
@ -1,7 +1,6 @@
|
|||
<?xml version="1.0"?>
|
||||
<ruleset>
|
||||
<rule ref="./vendor/mediawiki/mediawiki-codesniffer/MediaWiki">
|
||||
<exclude name="MediaWiki.Usage.NullableType.ExplicitNullableTypes" />
|
||||
<exclude name="MediaWiki.WhiteSpace.SpaceBeforeSingleLineComment.NewLineComment" />
|
||||
</rule>
|
||||
|
||||
|
|
|
@ -730,7 +730,7 @@ class TemplateDataBlobTest extends MediaWikiIntegrationTestCase {
|
|||
* @param stdClass $actual
|
||||
* @param string|null $message
|
||||
*/
|
||||
private function assertStrictJsonEquals( string $expected, stdClass $actual, string $message = null ): void {
|
||||
private function assertStrictJsonEquals( string $expected, stdClass $actual, ?string $message = null ): void {
|
||||
// Lazy recursive strict comparison: Serialise to JSON and compare that
|
||||
// Sort first to ensure key-order
|
||||
$expected = json_decode( $expected, /* assoc = */ true );
|
||||
|
|
Loading…
Reference in a new issue