mirror of https://github.com/go-gorm/gorm.git
Uncapitalize error strings (#2533)
This commit is contained in:
parent
d5cafb5db1
commit
13f19a5036
|
@ -17,7 +17,7 @@ func init() {
|
|||
// beforeDeleteCallback will invoke `BeforeDelete` method before deleting
|
||||
func beforeDeleteCallback(scope *Scope) {
|
||||
if scope.DB().HasBlockGlobalUpdate() && !scope.hasConditions() {
|
||||
scope.Err(errors.New("Missing WHERE clause while deleting"))
|
||||
scope.Err(errors.New("missing WHERE clause while deleting"))
|
||||
return
|
||||
}
|
||||
if !scope.HasError() {
|
||||
|
|
|
@ -34,7 +34,7 @@ func assignUpdatingAttributesCallback(scope *Scope) {
|
|||
// beforeUpdateCallback will invoke `BeforeSave`, `BeforeUpdate` method before updating
|
||||
func beforeUpdateCallback(scope *Scope) {
|
||||
if scope.DB().HasBlockGlobalUpdate() && !scope.hasConditions() {
|
||||
scope.Err(errors.New("Missing WHERE clause while updating"))
|
||||
scope.Err(errors.New("missing WHERE clause while updating"))
|
||||
return
|
||||
}
|
||||
if _, ok := scope.Get("gorm:update_column"); !ok {
|
||||
|
|
Loading…
Reference in New Issue