fix: handle None owner (#10497)

This commit is contained in:
Teddy 2023-03-10 09:12:14 +01:00 committed by GitHub
parent dccc139aad
commit cea10e8301
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -245,7 +245,7 @@ class TableauSource(DashboardServiceSource):
Returns:
Optional[EntityReference]
"""
if dashboard_details.owner.email:
if dashboard_details.owner and dashboard_details.owner.email:
user = self.metadata.get_user_by_email(dashboard_details.owner.email)
if user:
return EntityReference(id=user.id.__root__, type="user")