mirror of
https://github.com/qodo-ai/pr-agent.git
synced 2025-07-02 11:50:37 +08:00
Don't Display pr labels in the text
This commit is contained in:
@ -177,7 +177,11 @@ class PRDescription:
|
||||
pr_types = self.data['PR Labels']
|
||||
elif type(self.data['PR Labels']) == str:
|
||||
pr_types = self.data['PR Labels'].split(',')
|
||||
|
||||
elif 'PR Type' in self.data:
|
||||
if type(self.data['PR Type']) == list:
|
||||
pr_types = self.data['PR Type']
|
||||
elif type(self.data['PR Type']) == str:
|
||||
pr_types = self.data['PR Type'].split(',')
|
||||
return pr_types
|
||||
|
||||
def _prepare_pr_answer_with_markers(self) -> Tuple[str, str]:
|
||||
@ -223,6 +227,9 @@ class PRDescription:
|
||||
|
||||
# Iterate over the dictionary items and append the key and value to 'markdown_text' in a markdown format
|
||||
markdown_text = ""
|
||||
# Don't display 'PR Labels'
|
||||
if 'PR Labels' in self.data:
|
||||
self.data.pop('PR Labels')
|
||||
for key, value in self.data.items():
|
||||
markdown_text += f"## {key}\n\n"
|
||||
markdown_text += f"{value}\n\n"
|
||||
|
Reference in New Issue
Block a user