appview/pulls: do not mark merged PRs as abandoned upon resubmit #497

merged
opened by oppi.li targeting master from push-nnuvlyptxsqy
Changed files
+10
appview
pulls
+10
appview/pulls/pulls.go
··· 1713 1713 1714 1714 // deleted pulls are marked as deleted in the DB 1715 1715 for _, p := range deletions { 1716 + // do not do delete already merged PRs 1717 + if p.State == db.PullMerged { 1718 + continue 1719 + } 1720 + 1716 1721 err := db.DeletePull(tx, p.RepoAt, p.PullId) 1717 1722 if err != nil { 1718 1723 log.Println("failed to delete pull", err, p.PullId) ··· 1753 1758 op, _ := origById[id] 1754 1759 np, _ := newById[id] 1755 1760 1761 + // do not update already merged PRs 1762 + if op.State == db.PullMerged { 1763 + continue 1764 + } 1765 + 1756 1766 submission := np.Submissions[np.LastRoundNumber()] 1757 1767 1758 1768 // resubmit the old pull