Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function hasMethod(ClassReflection $classReflection, string $methodName):
$this->methods[$classReflection->getCacheKey()][$methodName] = $method;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in case this property is meant to be a cache, I think we could adjust the above IF case, as it effectively means a non-existant method will be checked for over and over again

}

return isset($this->methods[$classReflection->getCacheKey()][$methodName]);
return true;
}

public function getMethod(ClassReflection $classReflection, string $methodName): ExtendedMethodReflection
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public function hasProperty(ClassReflection $classReflection, string $propertyNa
$this->properties[$classReflection->getCacheKey()][$propertyName] = $property;
}

return isset($this->properties[$classReflection->getCacheKey()][$propertyName]);
return true;
}

public function getProperty(ClassReflection $classReflection, string $propertyName): ExtendedPropertyReflection
Expand Down
Loading