You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: globUtils.go
    path of file: ./repos/kubeshark/misc/fsUtils
    
    the code of the file until where you have to start completion: package fsUtils

import (
	"fmt"
	"os"
	"path/filepath"
)

func RemoveFilesByExtension(dirPath string, ext string) error {
	files, err := filepath.Glob(filepath.Join(dirPath, fmt.Sprintf("/*.%s", ext)))
	i
    
func RemoveFilesByExtension(dirPath string, ext string) error {
	files, err := filepath.Glob(filepath.Join(dirPath, fmt.Sprintf("/*.%s", ext)))
	if err != nil {
		return err
	}

	for _, f := range files {
		if err := os.Remove(f); err != nil {
			return err
		}
	}

	return nil
}