Skip to content

Commit

Permalink
Remove read-only changes for master branch (#169)
Browse files Browse the repository at this point in the history
Remove read-only changes for master branch
  • Loading branch information
Korbeil committed Oct 31, 2019
2 parents 7f9cec8 + e5f04be commit 6805721
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 1 addition & 3 deletions src/JsonSchema/Generator/ModelGenerator.php
Expand Up @@ -89,9 +89,7 @@ protected function doCreateClassMethods(ClassGuess $classGuess, Property $proper
{
$methods = [];
$methods[] = $this->createGetter($property, $namespace, $required);
if (!$property->isReadOnly()) {
$methods[] = $this->createSetter($property, $namespace, $required);
}
$methods[] = $this->createSetter($property, $namespace, $required);

return $methods;
}
Expand Down
4 changes: 1 addition & 3 deletions src/OpenApi/Generator/ModelGenerator.php
Expand Up @@ -18,9 +18,7 @@ protected function doCreateClassMethods(BaseClassGuess $classGuess, Property $pr
{
$methods = [];
$methods[] = $this->createGetter($property, $namespace, $required);
if (!$property->isReadOnly()) {
$methods[] = $this->createSetter($property, $namespace, $required, $classGuess instanceof MultipleClass ? false : true);
}
$methods[] = $this->createSetter($property, $namespace, $required, $classGuess instanceof MultipleClass ? false : true);

return $methods;
}
Expand Down

0 comments on commit 6805721

Please sign in to comment.