Skip to content

Commit

Permalink
replace null with empty enum set
Browse files Browse the repository at this point in the history
in addition to the fix in pr #144
  • Loading branch information
FabiKo117 authored Mar 18, 2021
1 parent 529faeb commit 97637d6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ Changelog
* fix some invalid filters in the default swagger examples ([#111])
* fix returning invalid GeoJSON using empty coordinates for deletion contributions ([#129], [#131])
* fix using a proper boolean data type instead of a string for contributionType in response ([#135])
* fix NPE with createOSMFeature ([#141])
* fix a null pointer exception in data extraction requests ([#141], [#145])
* make sure geometry filters are applied to all returned features of elementsFullHistory requests ([#109])

### Performance and Code Quality
Expand Down Expand Up @@ -37,6 +37,7 @@ Changelog
[#135]: https://github.com/GIScience/ohsome-api/pull/135
[#138]: https://github.com/GIScience/ohsome-api/issues/138
[#141]: https://github.com/GIScience/ohsome-api/issues/141
[#145]: https://github.com/GIScience/ohsome-api/pull/145


## 1.3.2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import java.io.Serializable;
import java.util.Collections;
import java.util.EnumSet;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
Expand Down Expand Up @@ -173,9 +174,9 @@ public List<Feature> buildUnchangedFeatures(OSMEntitySnapshot snapshot) {
properties.put("@validTo", endTimestamp);
boolean addToOutput = addEntityToOutput(entity, geom);
if (addToOutput) {
return Collections.singletonList(
exeUtils.createOSMFeature(entity, geom, properties, keysInt, includeTags,
includeOSMMetadata, isContributionsEndpoint, elementsGeometry, null));
return Collections.singletonList(exeUtils.createOSMFeature(entity, geom, properties,
keysInt, includeTags, includeOSMMetadata, isContributionsEndpoint, elementsGeometry,
EnumSet.noneOf(ContributionType.class)));
} else {
return Collections.emptyList();
}
Expand Down

0 comments on commit 97637d6

Please sign in to comment.