Skip to content

Commit

Permalink
Replace type func by isinstance in fab_security manager (#33760)
Browse files Browse the repository at this point in the history
  • Loading branch information
hussein-awala authored Aug 26, 2023
1 parent cfa5477 commit a44f261
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion airflow/www/fab_security/manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ def my_oauth_user_info(sm, provider, response=None):
def wraps(provider, response=None):
ret = f(self, provider, response=response)
# Checks if decorator is well behaved and returns a dict as supposed.
if not type(ret) == dict:
if not isinstance(ret, dict):
log.error("OAuth user info decorated function did not returned a dict, but: %s", type(ret))
return {}
return ret
Expand Down

0 comments on commit a44f261

Please sign in to comment.