allow empty prefix and no lead slash in bp route

This commit is contained in:
David Lord 2018-04-29 15:32:12 -07:00
parent 6b2127b1e0
commit f13870731c
No known key found for this signature in database
GPG key ID: 7A1C87E3F5BC42A8

View file

@ -65,7 +65,7 @@ class BlueprintSetupState(object):
to the application. The endpoint is automatically prefixed with the
blueprint's name.
"""
if self.url_prefix:
if self.url_prefix is not None:
rule = '/'.join((self.url_prefix, rule.lstrip('/')))
options.setdefault('subdomain', self.subdomain)
if endpoint is None: