Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

[PropertyInfo] Update List Information from ReflectionExtractor #16911

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Update ReflectionExtractor List Information
Unless a property with the same casing exists, lowercase the first letter of a name extracted from a method. Fixes #16889.
  • Loading branch information
Zander Baldwin committed Dec 9, 2015
commit b3011038413ab857af249b9d64ad2bc5f0982814
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,13 @@ public function getProperties($class, array $context = array())

foreach ($reflectionClass->getMethods(\ReflectionMethod::IS_PUBLIC) as $reflectionMethod) {
$propertyName = $this->getPropertyName($reflectionMethod->name);
if ($propertyName) {
$properties[$propertyName] = true;
if (!$propertyName || isset($properties[$propertyName])) {
continue;
}
if (!preg_match('/^[A-Z]{2,}/', $propertyName)) {
$propertyName = lcfirst($propertyName);
}
$properties[$propertyName] = true;
}

return array_keys($properties);
Expand Down
Morty Proxy This is a proxified and sanitized view of the page, visit original site.