Remove deleted milestones from merge requests
Closes https://github.com/gitlabhq/gitlabhq/issues/9643
This commit is contained in:
parent
abaa65efc1
commit
24a0e86dd3
1 changed files with 5 additions and 0 deletions
|
@ -0,0 +1,5 @@
|
|||
class RemoveInvalidMilestonesFromMergeRequests < ActiveRecord::Migration
|
||||
def up
|
||||
execute("UPDATE merge_requests SET milestone_id = NULL where milestone_id NOT IN (SELECT id FROM milestones)")
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue