mirror of
https://github.com/khoj-ai/khoj.git
synced 2024-12-18 18:47:11 +00:00
Update admin button for getting login url to include user email
This commit is contained in:
parent
88aa8c377a
commit
741e9f56f9
1 changed files with 1 additions and 1 deletions
|
@ -147,7 +147,7 @@ class KhojUserAdmin(UserAdmin, unfold_admin.ModelAdmin):
|
||||||
if user.email:
|
if user.email:
|
||||||
host = request.get_host()
|
host = request.get_host()
|
||||||
unique_id = user.email_verification_code
|
unique_id = user.email_verification_code
|
||||||
login_url = f"{host}/auth/magic?code={unique_id}"
|
login_url = f"{host}/auth/magic?code={unique_id}&email={user.email}"
|
||||||
messages.info(request, f"Email login URL for {user.email}: {login_url}")
|
messages.info(request, f"Email login URL for {user.email}: {login_url}")
|
||||||
|
|
||||||
get_email_login_url.short_description = "Get email login URL" # type: ignore
|
get_email_login_url.short_description = "Get email login URL" # type: ignore
|
||||||
|
|
Loading…
Reference in a new issue