diff options
author | ianb <devnull@localhost> | 2007-10-10 00:46:32 +0000 |
---|---|---|
committer | ianb <devnull@localhost> | 2007-10-10 00:46:32 +0000 |
commit | 995b34542ac862830425f09277af2c206f07baa1 (patch) | |
tree | 69ce642f7109f610ff42cd7dcaed902a04034740 /paste/debug | |
parent | 01398758f8fd83b91e3d7634a37d862a6ad19b34 (diff) | |
download | paste-995b34542ac862830425f09277af2c206f07baa1.tar.gz |
keep wdg_validate working when no content-type is set; also look for some other xhtml content types
Diffstat (limited to 'paste/debug')
-rw-r--r-- | paste/debug/wdg_validate.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/paste/debug/wdg_validate.py b/paste/debug/wdg_validate.py index 33de61a..119c2d7 100644 --- a/paste/debug/wdg_validate.py +++ b/paste/debug/wdg_validate.py @@ -59,9 +59,10 @@ class WDGValidateMiddleware(object): app_iter.close() page = output.getvalue() status, headers = response - v = wsgilib.header_value(headers, 'content-type') + v = wsgilib.header_value(headers, 'content-type') or '' if (not v.startswith('text/html') - and not v.startswith('text/xhtml+xml')): + and not v.startswith('text/xhtml') + and not v.startswith('application/xhtml')): # Can't validate # @@: Should validate CSS too... but using what? return [page] |