Skip to content

Commit 27d662f

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 70bd0c9 commit 27d662f

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

oauth2_provider/admin.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,8 @@
1414
get_refresh_token_model,
1515
)
1616

17-
has_email = hasattr(get_user_model(), 'email')
17+
18+
has_email = hasattr(get_user_model(), "email")
1819

1920

2021
class ApplicationAdmin(admin.ModelAdmin):
@@ -42,13 +43,11 @@ class GrantAdmin(admin.ModelAdmin):
4243

4344
class IDTokenAdmin(admin.ModelAdmin):
4445
list_display = ("jti", "user", "application", "expires")
45-
raw_id_fields = ("user", )
46+
raw_id_fields = ("user",)
4647
search_fields = ("token",) + (("user__email",) if has_email else ())
4748
list_filter = ("application",)
4849

4950

50-
51-
5251
class RefreshTokenAdmin(admin.ModelAdmin):
5352
list_display = ("token", "user", "application")
5453
raw_id_fields = ("user", "access_token")

0 commit comments

Comments
 (0)