Fix upsert if else

This commit is contained in:
Patrick O'brien 2016-09-15 14:59:48 +10:00
parent b3230c2757
commit 0abfe1cba6

View file

@ -127,10 +127,8 @@ func (o *{{$tableNameSingular}}) Upsert(exec boil.Executor, {{if ne .DriverName
{{- end}}
{{if not .NoHooks -}}
if err := o.doAfterUpsertHooks(exec); err != nil {
return err
}
{{- end}}
return o.doAfterUpsertHooks(exec)
{{- else -}}
return nil
{{- end}}
}