mislav/will_paginate — pull request #348 by ffmike (2013-12-14 20:37:12+00:00)
Title: Don't pass select option to count SQL

Somewhere in recent Rails master, a change was made that makes count blow up if a select option is supplied. End result is that

@companies = Company.select("companies.id, companies.type").paginate(:page => 1, :per_page => 25)

is blowing up with invalid SQL. Probably this should be fixed in Rails, but I don't think there's ever a point in passing specific fields to count SQL from will_paginate, so this seems like a good change to me anyhow.