Bug fix: Bytea nil values aren't stored as null in database.

This commit is contained in:
go-jet 2019-06-12 16:21:50 +02:00
parent c598978ba6
commit 038a4b9dd0
6 changed files with 29 additions and 15 deletions

View file

@ -74,7 +74,7 @@ func (c ColumnInfo) GoBaseType() string {
func (c ColumnInfo) GoModelType() string {
typeStr := c.GoBaseType()
if c.IsNullable && !strings.HasPrefix(typeStr, "[]") {
if c.IsNullable {
return "*" + typeStr
}