Propagate errors from SQL row reading (#1079)
Currently errors while data is being read are being swallowed and result in a truncated result set, this fixes that and properly returns an error and not an incomplete result.
This commit is contained in:
parent
e88d320934
commit
c5c275a261
|
@ -77,6 +77,9 @@ func (session *Session) nocacheGet(beanKind reflect.Kind, table *core.Table, bea
|
|||
defer rows.Close()
|
||||
|
||||
if !rows.Next() {
|
||||
if rows.Err() != nil {
|
||||
return false, rows.Err()
|
||||
}
|
||||
return false, nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue