138
138
def check_proposal(self):
139
139
"""Check that the submission is sensible."""
140
140
if self.source_branch.lp.self_link == self.target_branch.lp.self_link:
142
142
'Source and target branches must be different.')
143
143
for mp in self.source_branch.lp.landing_targets:
144
144
if mp.queue_status in ('Merged', 'Rejected'):
146
146
if mp.target_branch.self_link == self.target_branch.lp.self_link:
148
148
'There is already a branch merge proposal: %s') %
149
149
lp_api.canonical_url(mp))