summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorroot <admin@herely.us>2018-03-13 19:37:10 +0800
committerMarcel Hellkamp <marc@gsites.de>2018-03-13 14:36:17 +0100
commit1de24157e74a6971d136550afe1b63eec5b0df2b (patch)
tree2a5b2c6f9261c9d452cad4172f008c8e0da9dc33
parent862fe6b867f300654f6556543f3962b0b36a1651 (diff)
downloadbottle-1de24157e74a6971d136550afe1b63eec5b0df2b.tar.gz
fix code style
-rwxr-xr-xbottle.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/bottle.py b/bottle.py
index 7ef0ff8..8c689dd 100755
--- a/bottle.py
+++ b/bottle.py
@@ -645,7 +645,7 @@ class Bottle(object):
})
if kwargs.get('catchall') is False:
- depr(0,13, "Bottle(catchall) keyword argument.",
+ depr(0, 13, "Bottle(catchall) keyword argument.",
"The 'catchall' setting is now part of the app "
"configuration. Fix: `app.config['catchall'] = False`")
self.config['catchall'] = False
@@ -1603,12 +1603,14 @@ def _hkey(key):
raise ValueError("Header names must not contain control characters: %r" % key)
return key.title().replace('_', '-')
+
def _hval(value):
value = tonat(value)
if '\n' in value or '\r' in value or '\0' in value:
raise ValueError("Header value must not contain control characters: %r" % value)
return value
+
class HeaderProperty(object):
def __init__(self, name, reader=None, writer=None, default=''):
self.name, self.default = name, default