Fix the 'www.' strip changing the lstrip method by the replace
This commit is contained in:
parent
fe1f3ec06c
commit
596b435e57
@ -9,7 +9,7 @@ def bucket_name_from_url(url):
|
||||
domain = urlparse.urlparse(url).netloc
|
||||
|
||||
# If 'www' prefixed, strip it.
|
||||
domain = domain.lstrip("www.")
|
||||
domain = domain.replace("www.", "")
|
||||
|
||||
if 'amazonaws.com' in domain:
|
||||
bucket_result = bucket_name_regex.search(domain)
|
||||
|
Loading…
Reference in New Issue
Block a user