Skip to content

Commit ab0bc51

Browse files
committed
Fix a little spot bugs problem
1 parent 9020ae9 commit ab0bc51

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/main/java/org/mybatis/dynamic/sql/util/ValueMapping.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* Copyright 2016-2017 the original author or authors.
2+
* Copyright 2016-2019 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -23,8 +23,9 @@ public class ValueMapping<T> extends AbstractColumnMapping implements UpdateMapp
2323

2424
private Supplier<T> valueSupplier;
2525

26-
private ValueMapping(SqlColumn<T> column) {
26+
private ValueMapping(SqlColumn<T> column, Supplier<T> valueSupplier) {
2727
super(column);
28+
this.valueSupplier = valueSupplier;
2829
}
2930

3031
public T value() {
@@ -37,8 +38,7 @@ public <R> R accept(UpdateMappingVisitor<R> visitor) {
3738
}
3839

3940
public static <T> ValueMapping<T> of(SqlColumn<T> column, Supplier<T> valueSupplier) {
40-
ValueMapping<T> mapping = new ValueMapping<>(column);
41-
mapping.valueSupplier = valueSupplier;
41+
ValueMapping<T> mapping = new ValueMapping<>(column, valueSupplier);
4242
return mapping;
4343
}
4444
}

0 commit comments

Comments
 (0)