mirror of
https://github.com/qodo-ai/pr-agent.git
synced 2025-07-05 21:30:40 +08:00
refactor: Validate all required parameters before proceeding
Co-authored-by: ofir-frd <85901822+ofir-frd@users.noreply.github.com>
This commit is contained in:
@ -109,8 +109,8 @@ class PR_LineQuestions:
|
|||||||
file_path = get_settings().get('file_name', '')
|
file_path = get_settings().get('file_name', '')
|
||||||
line_number = get_settings().get('line_end', '')
|
line_number = get_settings().get('line_end', '')
|
||||||
|
|
||||||
# return if no comment id or file path and line number
|
# return if any required parameter is missing
|
||||||
if not (comment_id or (file_path and line_number)):
|
if not all([comment_id, file_path, line_number]):
|
||||||
return
|
return
|
||||||
|
|
||||||
# initialize conversation history
|
# initialize conversation history
|
||||||
|
Reference in New Issue
Block a user