Browse Source

调整命名更好理解

Signed-off-by: allan716 <[email protected]>
allan716 4 years ago
parent
commit
0f859eee80
1 changed files with 4 additions and 3 deletions
  1. 4 3
      downloader.go

+ 4 - 3
downloader.go

@@ -159,15 +159,16 @@ func (d Downloader)searchFile(dir string) ([]string, error) {
 			}
 		} else {
 			// 这里就是文件了
-			if d.isWantedExtDef(curFile.Name()) == true {
+			if d.isWantedVideoExtDef(curFile.Name()) == true {
 				fileFullPathList = append(fileFullPathList, fullPath)
 			}
 		}
 	}
 	return fileFullPathList, nil
 }
-// isWantedExtDef 后缀名是否符合规则
-func (d Downloader) isWantedExtDef(fileName string) bool {
+
+// isWantedVideoExtDef 后缀名是否符合规则
+func (d Downloader) isWantedVideoExtDef(fileName string) bool {
 	fileName = strings.ToLower(filepath.Ext(fileName))
 	for _, s := range d.wantedExtList {
 		if s == fileName {