Skip to content

Commit

Permalink
Merge pull request #627 from F43nd1r/bug626
Browse files Browse the repository at this point in the history
prevent urlencode nullpointer
  • Loading branch information
F43nd1r committed Jan 28, 2018
2 parents 2dfafe0 + 54ac38f commit fe90c85
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions acra-core/src/main/java/org/acra/data/StringFormat.java
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,8 @@ private void append(StringBuilder builder, String key, String value, String join
builder.append(joiner);
}
if (urlEncode) {
key = URLEncoder.encode(key, ACRAConstants.UTF8);
value = URLEncoder.encode(value, ACRAConstants.UTF8);
key = key != null ? URLEncoder.encode(key, ACRAConstants.UTF8) : null;
value = value != null ? URLEncoder.encode(value, ACRAConstants.UTF8) : null;
}
builder.append(key).append('=').append(value);
}
Expand Down

0 comments on commit fe90c85

Please sign in to comment.