File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed
src/main/java/io/github/jsonSnapshot Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ Add to your pom.xml dependencies section:
28
28
<dependency >
29
29
<groupId >io.github.json-snapshot</groupId >
30
30
<artifactId >json-snapshot</artifactId >
31
- <version >1.0.6 </version >
31
+ <version >1.0.7 </version >
32
32
</dependency >
33
33
```
34
34
Original file line number Diff line number Diff line change 5
5
<modelVersion >4.0.0</modelVersion >
6
6
<groupId >io.github.json-snapshot</groupId >
7
7
<artifactId >json-snapshot</artifactId >
8
- <version >1.0.6 </version >
8
+ <version >1.0.7 </version >
9
9
<packaging >jar</packaging >
10
10
11
11
<name >json-snapshot</name >
Original file line number Diff line number Diff line change @@ -34,7 +34,12 @@ public Object removeIgnored(Object value) {
34
34
try {
35
35
Field field = this .argumentClass .getDeclaredField (each );
36
36
field .setAccessible (true );
37
- field .set (newValue , null );
37
+ if (field .getType ().isPrimitive ()) {
38
+ field .setByte (newValue , Integer .valueOf (0 ).byteValue ());
39
+ }
40
+ else {
41
+ field .set (newValue , null );
42
+ }
38
43
} catch (IllegalAccessException | NoSuchFieldException e ) {
39
44
throw new SnapshotMatchException ("Invalid Ignore value " + each , e .getCause ());
40
45
}
You can’t perform that action at this time.
0 commit comments