Fixed typos across the codebase (can not, cannot)

This commit is contained in:
Denis Arh
2021-03-17 17:25:05 +01:00
parent a848c7d0b8
commit 79ed77a379
94 changed files with 117 additions and 118 deletions
+2 -2
View File
@@ -93,7 +93,7 @@ func Assign(base TypedValue, path string, val interface{}) error {
}
default:
return fmt.Errorf("can not set value on %s with path '%s'", base.Type(), path)
return fmt.Errorf("cannot set value on %s with path '%s'", base.Type(), path)
}
}
@@ -134,7 +134,7 @@ func Select(base TypedValue, path string) (TypedValue, error) {
}
var (
failure = fmt.Errorf("can not get value from %s with path '%s'", base.Type(), path)
failure = fmt.Errorf("cannot get value from %s with path '%s'", base.Type(), path)
key string
)
+2 -2
View File
@@ -50,11 +50,11 @@ func (t Unresolved) Type() string { return t.typ }
// Casts value to interface{}
func (Unresolved) Cast(interface{}) (TypedValue, error) {
return nil, fmt.Errorf("can not cast to unresolved type")
return nil, fmt.Errorf("cannot cast to unresolved type")
}
func (t *Unresolved) Assign(interface{}) (err error) {
return fmt.Errorf("can not set on unresolved type")
return fmt.Errorf("cannot set on unresolved type")
}
func CastToAny(val interface{}) (interface{}, error) {
+1 -1
View File
@@ -218,7 +218,7 @@ func (t *Vars) Scan(value interface{}) error {
case []uint8:
b := value.([]byte)
if err := json.Unmarshal(b, t); err != nil {
return fmt.Errorf("can not scan '%v' into %T: %w", string(b), t, err)
return fmt.Errorf("cannot scan '%v' into %T: %w", string(b), t, err)
}
}