Skip to content

Commit f75039a

Browse files
committed
Correct file/class name relation in sniff doc
Per PR PHPCSStandards#845, the filename must be modified to match the class name, since class names are much more restrictive than filenames and the inverse is not always possible. This clarifies in the example titles that the fix for the invalid code is to modify the filename rather than the class name.
1 parent 1e8f5db commit f75039a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Standards/Squiz/Docs/Classes/ClassFileNameStandard.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ class <em>Foo</em>
1414
}
1515
]]>
1616
</code>
17-
<code title="Invalid: Class name does not match filename.">
17+
<code title="Invalid: Filename does not match class name.">
1818
<![CDATA[
1919
/* ./src/<em>Foo.php</em> contents: */
2020
@@ -34,7 +34,7 @@ class <em>MyFoo</em>
3434
}
3535
]]>
3636
</code>
37-
<code title="Invalid: Class name case does not match filename case.">
37+
<code title="Invalid: Filename case does not match class name case.">
3838
<![CDATA[
3939
/* ./src/<em>myFoo.php</em> contents: */
4040

0 commit comments

Comments
 (0)