mirror of
https://github.com/qodo-ai/pr-agent.git
synced 2025-12-12 19:05:18 +00:00
Add null check
This commit is contained in:
parent
930cd69909
commit
48c29c9ffa
1 changed files with 4 additions and 0 deletions
|
|
@ -543,6 +543,10 @@ class GiteaProvider(GitProvider):
|
|||
self.logger.error("Failed to get PR branch")
|
||||
return ""
|
||||
|
||||
if not self.pr.head:
|
||||
self.logger.error("PR head not found")
|
||||
return ""
|
||||
|
||||
return self.pr.head.ref if self.pr.head.ref else ""
|
||||
|
||||
def get_pr_description_full(self) -> str:
|
||||
|
|
|
|||
Loading…
Reference in a new issue