1
0
mirror of https://github.com/volatiletech/authboss.git synced 2024-11-24 08:42:17 +02:00

Merge 'sunwukonga/master'

- Fixes the previously created test
This commit is contained in:
Aaron L 2017-01-09 08:52:45 -08:00
commit a401257db8

View File

@ -293,9 +293,11 @@ func (a Attributes) Bind(strct interface{}, ignoreMissing bool) error {
return errors.New("Bind: Was a scanner without a Scan method")
}
rvals := method.Call([]reflect.Value{reflect.ValueOf(v)})
if err, ok := rvals[0].Interface().(error); ok && err != nil {
return err
if v != nil {
rvals := method.Call([]reflect.Value{reflect.ValueOf(v)})
if err, ok := rvals[0].Interface().(error); ok && err != nil {
return err
}
}
continue