summaryrefslogtreecommitdiffstats
path: root/vendor/xorm.io/xorm/internal
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2021-01-05 14:28:51 +0800
committerGitHub <noreply@github.com>2021-01-05 14:28:51 +0800
commit126c9331d6d8789563fae5d5bac2196d63fee0e8 (patch)
tree304d5f1ce134bd75344a4e7e1a376d7a6dc9cfb1 /vendor/xorm.io/xorm/internal
parent8db0372a45082c8827bdee1b449f618b393c026d (diff)
downloadgitea-126c9331d6d8789563fae5d5bac2196d63fee0e8.tar.gz
gitea-126c9331d6d8789563fae5d5bac2196d63fee0e8.zip
upgrade xorm to v1.0.6 (#14246)
Diffstat (limited to 'vendor/xorm.io/xorm/internal')
-rw-r--r--vendor/xorm.io/xorm/internal/statements/statement.go4
-rw-r--r--vendor/xorm.io/xorm/internal/statements/update.go2
-rw-r--r--vendor/xorm.io/xorm/internal/statements/values.go2
3 files changed, 4 insertions, 4 deletions
diff --git a/vendor/xorm.io/xorm/internal/statements/statement.go b/vendor/xorm.io/xorm/internal/statements/statement.go
index ed7bdaeb62..a4294bec6d 100644
--- a/vendor/xorm.io/xorm/internal/statements/statement.go
+++ b/vendor/xorm.io/xorm/internal/statements/statement.go
@@ -704,7 +704,7 @@ func (statement *Statement) buildConds2(table *schemas.Table, bean interface{},
col.SQLType.IsBlob() || col.SQLType.Name == schemas.TimeStampz) {
continue
}
- if col.SQLType.IsJson() {
+ if col.IsJSON {
continue
}
@@ -813,7 +813,7 @@ func (statement *Statement) buildConds2(table *schemas.Table, bean interface{},
continue
}
} else {
- if col.SQLType.IsJson() {
+ if col.IsJSON {
if col.SQLType.IsText() {
bytes, err := json.DefaultJSONHandler.Marshal(fieldValue.Interface())
if err != nil {
diff --git a/vendor/xorm.io/xorm/internal/statements/update.go b/vendor/xorm.io/xorm/internal/statements/update.go
index ff5f82b731..251880b230 100644
--- a/vendor/xorm.io/xorm/internal/statements/update.go
+++ b/vendor/xorm.io/xorm/internal/statements/update.go
@@ -204,7 +204,7 @@ func (statement *Statement) BuildUpdates(tableValue reflect.Value,
continue
}
} else {
- if !col.SQLType.IsJson() {
+ if !col.IsJSON {
table, err := statement.tagParser.ParseWithCache(fieldValue)
if err != nil {
val = fieldValue.Interface()
diff --git a/vendor/xorm.io/xorm/internal/statements/values.go b/vendor/xorm.io/xorm/internal/statements/values.go
index 99eaa76691..71327c5568 100644
--- a/vendor/xorm.io/xorm/internal/statements/values.go
+++ b/vendor/xorm.io/xorm/internal/statements/values.go
@@ -86,7 +86,7 @@ func (statement *Statement) Value2Interface(col *schemas.Column, fieldValue refl
return t.Float64, nil
}
- if !col.SQLType.IsJson() {
+ if !col.IsJSON {
// !<winxxp>! 增加支持driver.Valuer接口的结构,如sql.NullString
if v, ok := fieldValue.Interface().(driver.Valuer); ok {
return v.Value()