func GetFiles(dir string) ([]fs.FileInfo, error) {

	//Try and get files
	files, err := ioutil.ReadDir(dir)
	if err != nil {
		return nil, err
	}

	out := make([]fs.FileInfo, 0, len(files))
	for _, f := range files {
		if !f.IsDir() {
			out = append(out, f)
		}
	}

	//Return
	return out, nil
}
//Get files from folder in alphabethical order
Get files from folder in alphabethical order
// Get files from folder in alphabethical order
func GetFiles(dir string) ([]fs.FileInfo, error) {
	files, err := ioutil.ReadDir(dir)
	if err != nil {
		return nil, err
	}
	out := make([]fs.FileInfo, 0, len(files))
	for _, f := range files {
		if !f.IsDir() {
			out = append(out, f)
		}
	}
	return out, nil
}
func GetFiles ( dir string ) ( [ ] fs . FileInfo , error ) { files , err := ioutil . ReadDir ( dir ) if err != nil { return nil , err } out := make ( [ ] fs . FileInfo , 0 , len ( files ) ) for _ , f := range files { if ! f . IsDir ( ) { out = append ( out , f ) } } return out , nil }
Get files from folder in alphabethical order
Get files from folder in alphabethical order
//Try and get files //Return