Sho SHIMIZU
Committed by Sho Shimizu

Cosmetics

Change-Id: I46c79068f9de3451483b63e8963143ab283cf53b
...@@ -84,9 +84,7 @@ final class EncodableDiscreteResources implements DiscreteResources { ...@@ -84,9 +84,7 @@ final class EncodableDiscreteResources implements DiscreteResources {
84 84
85 @Override 85 @Override
86 public DiscreteResources difference(DiscreteResources other) { 86 public DiscreteResources difference(DiscreteResources other) {
87 - Set<DiscreteResource> diff = Sets.difference(values(), other.values()); 87 + return of(parent, Sets.difference(values(), other.values()));
88 -
89 - return of(parent, diff);
90 } 88 }
91 89
92 @Override 90 @Override
......
...@@ -58,7 +58,7 @@ final class GenericDiscreteResources implements DiscreteResources { ...@@ -58,7 +58,7 @@ final class GenericDiscreteResources implements DiscreteResources {
58 58
59 @Override 59 @Override
60 public DiscreteResources difference(DiscreteResources other) { 60 public DiscreteResources difference(DiscreteResources other) {
61 - return new GenericDiscreteResources(Sets.difference(this.values, other.values())); 61 + return of(Sets.difference(this.values(), other.values()));
62 } 62 }
63 63
64 @Override 64 @Override
......
...@@ -65,7 +65,7 @@ final class UnifiedDiscreteResources implements DiscreteResources { ...@@ -65,7 +65,7 @@ final class UnifiedDiscreteResources implements DiscreteResources {
65 65
66 @Override 66 @Override
67 public DiscreteResources difference(DiscreteResources other) { 67 public DiscreteResources difference(DiscreteResources other) {
68 - return of(Sets.difference(values(), other.values())); 68 + return of(Sets.difference(this.values(), other.values()));
69 } 69 }
70 70
71 @Override 71 @Override
......