diff options
author | 2021-09-23 11:13:28 +0200 | |
---|---|---|
committer | 2021-09-23 11:13:28 +0200 | |
commit | 142f37f1bd0291f74e12002931d05174f3a31741 (patch) | |
tree | d2e5d80df32a0217a442cfd9ba207d5e88879b77 /vendor/github.com/uptrace/bun/schema/field.go | |
parent | update media processing (#244) (diff) | |
download | gotosocial-142f37f1bd0291f74e12002931d05174f3a31741.tar.xz |
upstep bun version (#243)
Diffstat (limited to 'vendor/github.com/uptrace/bun/schema/field.go')
-rw-r--r-- | vendor/github.com/uptrace/bun/schema/field.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/vendor/github.com/uptrace/bun/schema/field.go b/vendor/github.com/uptrace/bun/schema/field.go index 1e069b82f..59990b924 100644 --- a/vendor/github.com/uptrace/bun/schema/field.go +++ b/vendor/github.com/uptrace/bun/schema/field.go @@ -101,7 +101,9 @@ func (f *Field) ScanValue(strct reflect.Value, src interface{}) error { func (f *Field) markAsPK() { f.IsPK = true f.NotNull = true - f.NullZero = true + if !f.Tag.HasOption("allowzero") { + f.NullZero = true + } } func indexEqual(ind1, ind2 []int) bool { |