[Fix]: don't access secrets if doesn't exist (#8535)

Co-authored-by: openhands <openhands@all-hands.dev>
This commit is contained in:
Rohit Malhotra 2025-05-16 10:30:16 -04:00 committed by GitHub
parent 8ec5d0e043
commit c191a17afb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -215,7 +215,7 @@ async def new_conversation(
agent_loop_info = await _create_new_conversation(
user_id=user_id,
git_provider_tokens=provider_tokens,
custom_secrets=user_secrets.custom_secrets,
custom_secrets=user_secrets.custom_secrets if user_secrets else None,
selected_repository=repository,
selected_branch=selected_branch,
initial_user_msg=initial_user_msg,