Skip to content

Commit b9966a9

Browse files
committed
minor #32786 add parameter type declarations to private methods (xabbuh)
This PR was merged into the 4.4 branch. Discussion ---------- add parameter type declarations to private methods | Q | A | ------------- | --- | Branch? | 4.4 | Bug fix? | no | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | | License | MIT | Doc PR | Commits ------- 1b2aaa4a06 add parameter type declarations to private methods
2 parents c98f116 + 3b8ed1f commit b9966a9

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

Definition/Dumper/YamlReferenceDumper.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ private function writeLine(string $text, int $indent = 0)
182182
$this->reference .= sprintf($format, $text)."\n";
183183
}
184184

185-
private function writeArray(array $array, $depth)
185+
private function writeArray(array $array, int $depth)
186186
{
187187
$isIndexed = array_values($array) === $array;
188188

FileLocator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ public function locate($name, $currentPath = null, $first = true)
8181
*
8282
* @return bool
8383
*/
84-
private function isAbsolutePath($file)
84+
private function isAbsolutePath(string $file)
8585
{
8686
if ('/' === $file[0] || '\\' === $file[0]
8787
|| (\strlen($file) > 3 && ctype_alpha($file[0])

Loader/FileLoader.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ protected function glob(string $pattern, bool $recursive, &$resource = null, boo
125125
yield from $resource;
126126
}
127127

128-
private function doImport($resource, $type = null, bool $ignoreErrors = false, $sourceResource = null)
128+
private function doImport($resource, string $type = null, bool $ignoreErrors = false, $sourceResource = null)
129129
{
130130
try {
131131
$loader = $this->resolve($resource, $type);

ResourceCheckerConfigCache.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ private function getMetaFile()
152152
return $this->file.'.meta';
153153
}
154154

155-
private function safelyUnserialize($file)
155+
private function safelyUnserialize(string $file)
156156
{
157157
$e = null;
158158
$meta = false;

0 commit comments

Comments
 (0)