public function is_entry_meta(): bool {
return true;
}
phpcs will tell you:
Remove empty line before return statement in ... line.
(WPForms.Formatting.EmptyLineBeforeReturn.RemoveEmptyLineBeforeReturnStatement) phpcs
if you remove empty line so method will be:
public function is_entry_meta(): bool {
return true;
}
phpcs will tell you:
Add empty line after is_entry_meta() function declaration.
(WPForms.Formatting.EmptyLineAfterFunctionDeclaration.AddEmptyLineAfterFunctionDeclaration) phpcs
This problem does not exist if method does not have return type hinting:
public function is_entry_meta() {
return true;
}
Expected Behavior
Methods - no matter if they have return type hinting or not, should have empty line after function declaration (so the first code snippet above should be valid).
Originally reported by @kkarpieszuk in https://github.com/awesomemotive/wpforms-plugin/issues/8417
Current Behavior
If you define method:
phpcs will tell you:
if you remove empty line so method will be:
phpcs will tell you:
This problem does not exist if method does not have return type hinting:
Expected Behavior
Methods - no matter if they have return type hinting or not, should have empty line after function declaration (so the first code snippet above should be valid).