Skip to content

Commit

Permalink
chore: Prepare release branch for new release (#216)
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeproeng37 authored Sep 21, 2018
1 parent 40ee4a0 commit a85dac7
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,6 @@ cache:
branches:
only:
- master
- /^\d+\.\d+\.\d+(-SNAPSHOT|-alpha|-beta)?\d*$/ # trigger builds on tags which are semantically versioned to ship the SDK.
- /^\d+\.\d+\.(\d|[x])+(-SNAPSHOT|-alpha|-beta)?\d*$/ # trigger builds on tags which are semantically versioned to ship the SDK.
after_success:
- ./gradlew coveralls uploadArchives --console plain
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# Optimizely Java X SDK Changelog

## 2.1.3

September 21st, 2018

### Bug Fixes
* fix(attributes): Filters out attributes with null values from the event payload ([#204](https://github.com/optimizely/java-sdk/pull/204))

## 2.1.2

August 1st, 2018
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,19 @@ public LogEvent createConversionEvent(@Nonnull ProjectConfig projectConfig,
private List<Attribute> buildAttributeList(ProjectConfig projectConfig, Map<String, String> attributes) {
List<Attribute> attributesList = new ArrayList<Attribute>();

for (Map.Entry<String, String> entry : attributes.entrySet()) {
for (Map.Entry<String, ?> entry : attributes.entrySet()) {
// Filter down to the types of values we're allowed to track.
// Don't allow Longs, BigIntegers, or BigDecimals - they /can/ theoretically be serialized as JSON numbers
// but may take on values that can't be faithfully parsed by the backend.
// https://developers.optimizely.com/x/events/api/#Attribute
if (entry.getValue() == null ||
!((entry.getValue() instanceof String) ||
(entry.getValue() instanceof Integer) ||
(entry.getValue() instanceof Double) ||
(entry.getValue() instanceof Boolean))) {
continue;
}

String attributeId = projectConfig.getAttributeId(projectConfig, entry.getKey());
if(attributeId == null) {
continue;
Expand Down

0 comments on commit a85dac7

Please sign in to comment.