Skip to content

Commit

Permalink
Fixed potential NPE
Browse files Browse the repository at this point in the history
  • Loading branch information
gastaldi committed Apr 10, 2014
1 parent 2c5600e commit dd73d55
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ else if (member instanceof Field)
for (Method<?, ?> method : entity.getMethods())
{
// It's a getter
if (method.getParameters().size() == 0 && type.equals(method.getReturnType().getQualifiedName()))
if (method.getParameters().size() == 0 && (method.getReturnType() != null && type.equals(method.getReturnType().getQualifiedName())))
{
if (method.getName().toLowerCase().contains(name.toLowerCase()))
{
Expand Down

0 comments on commit dd73d55

Please sign in to comment.