Adds support for Rails 4 in addition to rails 3