OSDN Git Service

Consolidate functionality shared between Issue and MergeRequest
authorRobert Speicher <rspeicher@gmail.com>
Thu, 9 Aug 2012 01:40:57 +0000 (21:40 -0400)
committerRobert Speicher <rspeicher@gmail.com>
Thu, 9 Aug 2012 01:44:33 +0000 (21:44 -0400)
commitf36f0dac9d2a009f29d2253dcd7c66d5a46ffd56
tree60dd3e641ce7fc44dc7283f8a1e3732a9a0aedf0
parent7a4c95888225bf465187f9a186fb5373e8405a5f
Consolidate functionality shared between Issue and MergeRequest

Any associations, validations, delegates, scopes and methods that
were exactly the same in both Issue and MergeRequest models have been
moved to a new IssueCommonality module (role) that gets included by each
class.

There was actually quite a bit of duplication, because MergeRequests are
basically just specialized Issues.
app/models/issue.rb
app/models/merge_request.rb
app/roles/issue_commonality.rb