Remove duplicated code (#1991)
Reviewed-on: https://gitea.com/xorm/xorm/pulls/1991 Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-committed-by: Lunny Xiao <xiaolunwen@gmail.com>
This commit is contained in:
parent
69a7db5312
commit
779a74ccff
|
@ -268,12 +268,6 @@ func (session *Session) getVars(rows *core.Rows, types []*sql.ColumnType, fields
|
|||
}
|
||||
|
||||
func (session *Session) getStruct(rows *core.Rows, types []*sql.ColumnType, fields []string, table *schemas.Table, bean interface{}) (bool, error) {
|
||||
fields, err := rows.Columns()
|
||||
if err != nil {
|
||||
// WARN: Alougth rows return true, but get fields failed
|
||||
return true, err
|
||||
}
|
||||
|
||||
scanResults, err := session.row2Slice(rows, fields, bean)
|
||||
if err != nil {
|
||||
return false, err
|
||||
|
|
Loading…
Reference in New Issue