Code

fix the filename fallback
authorrichard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2>
Tue, 20 Jan 2004 05:55:24 +0000 (05:55 +0000)
committerrichard <richard@57a73879-2fb5-44c3-a270-3262357dd7e2>
Tue, 20 Jan 2004 05:55:24 +0000 (05:55 +0000)
git-svn-id: http://svn.roundup-tracker.org/svnroot/roundup/trunk@2055 57a73879-2fb5-44c3-a270-3262357dd7e2

roundup/cgi/client.py

index b53a38cd8c6d812643817ea2295eb0eec19a4a2b..672f89918b5b96777dced1e9581872d95411f96b 100644 (file)
@@ -1,4 +1,4 @@
-# $Id: client.py,v 1.153 2004-01-20 03:58:38 richard Exp $
+# $Id: client.py,v 1.154 2004-01-20 05:55:24 richard Exp $
 
 __doc__ = """
 WWW request handler (also used in the stand-alone server).
@@ -1778,7 +1778,7 @@ You should then receive another email with the new password.
                                 props['name'] = fn
                             # use this info as the type/filename properties
                             if propdef.has_key('type'):
-                                if hasattr(value, 'type'):
+                                if hasattr(value, 'type') and value.type:
                                     props['type'] = value.type
                                 elif mimetypes.guess_type(fn)[0]:
                                     props['type'] = mimetypes.guess_type(fn)[0]