fix: allow api call in stream route + get_prompt error

This commit is contained in:
Siddhant Rai
2025-07-25 16:17:18 +05:30
parent 76973a4b4c
commit 212952f3e9
3 changed files with 3 additions and 4 deletions

View File

@@ -63,7 +63,8 @@ class AnswerResource(Resource, BaseAnswerResource):
data = request.get_json()
if error := self.validate_request(data):
return error
processor = StreamProcessor(data, None)
decoded_token = getattr(request, "decoded_token", None)
processor = StreamProcessor(data, decoded_token)
try:
processor.initialize()
if not processor.decoded_token: