fixed bug if input dir doesn't exist.
This commit is contained in:
parent
a37d88f99f
commit
126a948fd4
@ -53,6 +53,9 @@ func Source(root string) <-chan string {
|
|||||||
err := filepath.Walk(
|
err := filepath.Walk(
|
||||||
root,
|
root,
|
||||||
func(path string, info os.FileInfo, err error) error {
|
func(path string, info os.FileInfo, err error) error {
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
if info.IsDir() {
|
if info.IsDir() {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user