Use reports_count so that counter_cache works automatically.
authorAndy Allan <git@gravitystorm.co.uk>
Wed, 6 Sep 2017 16:57:54 +0000 (17:57 +0100)
committerAndy Allan <git@gravitystorm.co.uk>
Wed, 6 Sep 2017 16:57:54 +0000 (17:57 +0100)
commit948fd8c8faf1016deb23b73eca0dadb6267603cf
treee7a3649475061cfc545938b376c85f3af112d854
parentb578cee7597fbf4ea6e20ce3e9134dade790a80b
Use reports_count so that counter_cache works automatically.
app/models/report.rb
app/views/issues/index.html.erb
db/migrate/20160822153153_add_reports_count_to_issues.rb [moved from db/migrate/20160822153153_add_report_count_to_issues.rb with 59% similarity]