Skip to content

Commit

Permalink
pool domain should always return a domain
Browse files Browse the repository at this point in the history
  • Loading branch information
baohx2000 authored Feb 17, 2021
1 parent d3ad9d6 commit b244f91
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion moto/cognitoidp/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,8 @@ def _distribution_name(self):
self.custom_domain_config["CertificateArn"].encode("utf-8")
).hexdigest()
return "{hash}.cloudfront.net".format(hash=hash[:16])
return None
hash = hashlib.md5(self.user_pool_id).hexdigest()
return "{hash}.amazoncognito.com".format(hash=hash[:16])

def to_json(self, extended=True):
distribution = self._distribution_name()
Expand Down

0 comments on commit b244f91

Please sign in to comment.