Skip to content

Commit

Permalink
Fix REQUIRE_SETTERS_FOR_GETTERS taking no effect (#4257)
Browse files Browse the repository at this point in the history
  • Loading branch information
JooHyukKim authored Dec 15, 2023
1 parent 6b40662 commit 9e147a8
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,11 @@ public Class<?> getRawPrimaryType() {

@Override
public boolean couldDeserialize() {
return (_ctorParameters != null) || (_setters != null) || (_fields != null);
return (_ctorParameters != null)
|| (_setters != null)
|| ((_fields != null)
// [databind#736] Since 2.16 : Fix `REQUIRE_SETTERS_FOR_GETTERS` taking no effect
&& (_anyVisible(_fields)));
}

@Override
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.fasterxml.jackson.failing;
package com.fasterxml.jackson.databind.ser;

import com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility;
import com.fasterxml.jackson.annotation.PropertyAccessor;
Expand Down

0 comments on commit 9e147a8

Please sign in to comment.