mirror of
https://github.com/khoj-ai/khoj.git
synced 2025-02-17 08:04:21 +00:00
Add the url scheme to the public share url
This commit is contained in:
parent
f6aaecb04f
commit
cf0b7628d0
1 changed files with 4 additions and 1 deletions
|
@ -262,6 +262,7 @@ def duplicate_chat_history_public_conversation(
|
|||
public_conversation_url = PublicConversationAdapters.get_public_conversation_url(public_conversation)
|
||||
|
||||
domain = request.headers.get("host")
|
||||
scheme = request.url.scheme
|
||||
|
||||
update_telemetry_state(
|
||||
request=request,
|
||||
|
@ -270,7 +271,9 @@ def duplicate_chat_history_public_conversation(
|
|||
**common.__dict__,
|
||||
)
|
||||
|
||||
return Response(status_code=200, content=json.dumps({"status": "ok", "url": f"{domain}{public_conversation_url}"}))
|
||||
return Response(
|
||||
status_code=200, content=json.dumps({"status": "ok", "url": f"{scheme}://{domain}{public_conversation_url}"})
|
||||
)
|
||||
|
||||
|
||||
@api_chat.get("/sessions")
|
||||
|
|
Loading…
Add table
Reference in a new issue