discourse/discourse — pull request #1708 by chancancode (2013-11-30 06:05:07+00:00)
Title: Don't abuse as_json, it's not meant for consumption

The `as_json` API is a hook for JSON encoders to call, not meant for
consumption like this, and the result is not guarenteed to be stable
across Rails versions.

There might be other cases like this that we should revisit later, but
this one in particular is causing a test to fail on Rails master.