From dc057e43e4aa814822943d8f28ebb51ffde565f6 Mon Sep 17 00:00:00 2001 From: Thomas Leonard Date: Sat, 23 Jul 2011 13:06:38 +0100 Subject: [PATCH] Recognise the .tar.gz extension as well as .tgz --- mimetypes.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mimetypes.py b/mimetypes.py index b953b85..fac8751 100644 --- a/mimetypes.py +++ b/mimetypes.py @@ -17,7 +17,7 @@ def add_types(data): if not type: if href.endswith('.tar.bz2'): type = "application/x-bzip-compressed-tar" - elif href.endswith('.tgz'): + elif href.endswith('.tgz') or href.endswith('.tar.gz'): type = "application/x-compressed-tar" else: raise Exception("Can't guess type for " + href) -- 2.11.4.GIT