Skip to content

Commit

Permalink
Fix prompt access
Browse files Browse the repository at this point in the history
  • Loading branch information
Weves committed Jun 6, 2024
1 parent 1fb47d7 commit 41fbaf5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion backend/danswer/one_shot_answer/answer_question.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,10 @@ def stream_answer_objects(

prompt = None
if query_req.prompt_id is not None:
# NOTE: let the user access any prompt as long as the Persona is shared
# with them
prompt = get_prompt_by_id(
prompt_id=query_req.prompt_id, user=user, db_session=db_session
prompt_id=query_req.prompt_id, user=None, db_session=db_session
)
if prompt is None:
if not chat_session.persona.prompts:
Expand Down

0 comments on commit 41fbaf5

Please sign in to comment.