(option FileOption, df FileSearchInfo)
| 453 | } |
| 454 | |
| 455 | func (f *FileInfo) getFilePathAndName(option FileOption, df FileSearchInfo) (string, string) { |
| 456 | name := df.Name() |
| 457 | fPath := path.Join(df.Path, df.Name()) |
| 458 | |
| 459 | if option.Search != "" && option.ContainSub { |
| 460 | fPath = df.Path |
| 461 | name = strings.TrimPrefix(strings.TrimPrefix(fPath, f.Path), "/") |
| 462 | } |
| 463 | |
| 464 | return name, fPath |
| 465 | } |
| 466 | |
| 467 | func (f *FileInfo) checkSymlink(df FileSearchInfo) (bool, bool) { |
| 468 | isSymlink := false |