Rails4 support + some small fixes

I've found some useful commits of @vast (rails4 support) and added some bugfixes from my side.

With this, `api_taster` works completely for me now with rails4.