rails/rails — pull request #6937 by eignerchris (2012-07-02 23:42:53+00:00)
Title: Adds zero_counter method for zeroing out counter caches

There exists no way to zero out counter caches other than to iterate over every record and call #reset_counters. This commit adds a #zero_counter method that zeros out the supplied counter.

`Usage: Topic.zero_counter(:replies)`