decorator: Remove now-unnecessary cast.

This commit is contained in:
Tim Abbott 2017-08-14 15:47:54 -07:00
parent 5ebe507c9b
commit 5b8d04e18f
1 changed files with 0 additions and 1 deletions

View File

@ -203,7 +203,6 @@ def validate_api_key(request, role, api_key, is_webhook=False):
if api_key != profile.api_key: if api_key != profile.api_key:
raise JsonableError(_("Invalid API key")) raise JsonableError(_("Invalid API key"))
profile = cast(UserProfile, profile) # is UserProfile
if not profile.is_active: if not profile.is_active:
raise JsonableError(_("Account not active")) raise JsonableError(_("Account not active"))
if profile.realm.deactivated: if profile.realm.deactivated: