cakephp/cakephp — pull request #4846 by dakota (2014-10-09 12:06:22+00:00)
Title: 3.0 counter cache error with lambda counters

When using counterCache with a lambda counter, it would error if the entity foreign_key is updated as it was calling _getCount() with the lambda (and _getCount expects an array)

I added in a $original argument to the counterCache callable to determine what part of the count is being called.