filtering all except png and jpg
This commit is contained in:
parent
a4a6cce943
commit
958631df5d
@ -26,7 +26,10 @@ func ScanLocalFileStructure(path string) (map[string]*FilesystemNode, error) {
|
||||
return nil
|
||||
}
|
||||
|
||||
//TODO: Only allow jpg and png files here
|
||||
extension := strings.ToLower(filepath.Ext(path))
|
||||
if extension != ".jpg" && extension != ".png" {
|
||||
return nil
|
||||
}
|
||||
|
||||
key := strings.Replace(path, fullPathReplace, "", 1)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user