Skip to content

Instantly share code, notes, and snippets.

@edap
Last active August 29, 2015 14:03
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save edap/bd1d6788ecf09af9580e to your computer and use it in GitHub Desktop.
func isImage(filename string) bool {
is_img, _ := regexp.MatchString("(?i)\\.(png|jpg|jpeg|gif)$", filename)
return is_img
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment