mirror of
https://github.com/odoo/runbot.git
synced 2025-03-15 15:35:46 +07:00
[FIX] runbot_merge: allow source author to r- forward ports
Noticed that while writing up the docs on the wiki, seems like an unnecessary restriction, and an inconvenient one to boot: the author could r+, then realize they forgot to do an update they needed to do on the fw, so they should be able to cancel the staging without needing a reviewer.
This commit is contained in:
parent
0a839a4857
commit
286c1fdaee
@ -652,7 +652,7 @@ class PullRequests(models.Model):
|
||||
commands.Help,
|
||||
|
||||
(self.source_id and (source_author or source_reviewer) or is_reviewer) and not self.reviewed_by and commands.Approve,
|
||||
is_author and self.reviewed_by and commands.Reject,
|
||||
(is_author or source_author) and self.reviewed_by and commands.Reject,
|
||||
(is_author or source_author) and self.error and commands.Retry,
|
||||
|
||||
is_author and not self.source_id and commands.FW,
|
||||
@ -783,7 +783,7 @@ For your own safety I've ignored *everything in your entire comment*.
|
||||
msg = f"tried to approve PRs {command.ids} but the current PR is {self.number}"
|
||||
else:
|
||||
msg = self._approve(author, login)
|
||||
case commands.Reject() if is_author:
|
||||
case commands.Reject() if is_author or source_author:
|
||||
if self.batch_id.skipchecks or self.reviewed_by:
|
||||
if self.error:
|
||||
self.error = False
|
||||
|
Loading…
Reference in New Issue
Block a user