Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:RPTools/maptool into fix-3645
Browse files Browse the repository at this point in the history
  • Loading branch information
cwisniew committed Sep 21, 2022
2 parents 07386dd + 827e535 commit b273423
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
11 changes: 7 additions & 4 deletions src/main/java/net/rptools/maptool/model/Campaign.java
Original file line number Diff line number Diff line change
Expand Up @@ -773,10 +773,13 @@ public CampaignDto toDto() {
.map(MacroButtonProperties::toDto)
.collect(Collectors.toList()));
dto.addAllZones(zones.values().stream().map(Zone::toDto).collect(Collectors.toList()));
dto.addAllGmMacroButtonProperties(
gmMacroButtonProperties.stream()
.map(MacroButtonProperties::toDto)
.collect(Collectors.toList()));
// gmMacroButtonProperties is null if you are loading an old campaign file < 1.5.6
if (gmMacroButtonProperties != null) {
dto.addAllGmMacroButtonProperties(
gmMacroButtonProperties.stream()
.map(MacroButtonProperties::toDto)
.collect(Collectors.toList()));
}
return dto.build();
}
}
2 changes: 1 addition & 1 deletion src/main/java/net/rptools/maptool/model/Token.java
Original file line number Diff line number Diff line change
Expand Up @@ -1725,7 +1725,7 @@ public Object setState(String aState, Object aValue) {
// setBarVisible sends a boolean to show/hide a bar
if (aValue instanceof Boolean) {
if ((Boolean) aValue) {
return state.put(aState, 1.0);
return state.put(aState, aValue);
} else {
return state.remove(aState);
}
Expand Down

0 comments on commit b273423

Please sign in to comment.