1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-06-15 00:15:32 +02:00

chore: use errors.New to replace fmt.Errorf with no parameters.

This commit is contained in:
ChengenH
2024-04-24 16:21:34 +08:00
parent 0a5e9b2d60
commit dd6bfa1680
4 changed files with 12 additions and 9 deletions

View File

@ -1,7 +1,7 @@
package oscommands
import (
"fmt"
"errors"
"io"
"os"
"path/filepath"
@ -86,7 +86,7 @@ func CopyDir(src string, dst string) (err error) {
return err
}
if !si.IsDir() {
return fmt.Errorf("source is not a directory")
return errors.New("source is not a directory")
}
_, err = os.Stat(dst)