support git providers with no label support

This commit is contained in:
Hussam.lawen
2023-11-06 14:11:49 +02:00
parent e96b03da57
commit db37ee819a
2 changed files with 12 additions and 5 deletions

View File

@ -228,7 +228,7 @@ 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:
if 'PR Labels' in self.data and self.git_provider.is_supported("get_labels"):
self.data.pop('PR Labels')
if not get_settings().pr_description.enable_pr_type:
self.data.pop('PR Type')