mirror of
https://github.com/rclone/rclone.git
synced 2025-06-05 20:34:39 +08:00
Error strings should not be capitalized
Reported by staticcheck 2022.1.2 (v0.3.2) See: staticcheck.io
This commit is contained in:
@ -38,7 +38,7 @@ func (m *CutoffMode) Set(s string) error {
|
||||
return nil
|
||||
}
|
||||
}
|
||||
return fmt.Errorf("Unknown cutoff mode %q", s)
|
||||
return fmt.Errorf("unknown cutoff mode %q", s)
|
||||
}
|
||||
|
||||
// Type of the value
|
||||
@ -50,7 +50,7 @@ func (m *CutoffMode) Type() string {
|
||||
func (m *CutoffMode) UnmarshalJSON(in []byte) error {
|
||||
return UnmarshalJSONFlag(in, m, func(i int64) error {
|
||||
if i < 0 || i >= int64(len(cutoffModeToString)) {
|
||||
return fmt.Errorf("Out of range cutoff mode %d", i)
|
||||
return fmt.Errorf("out of range cutoff mode %d", i)
|
||||
}
|
||||
*m = (CutoffMode)(i)
|
||||
return nil
|
||||
|
Reference in New Issue
Block a user