Fixes Rails 4 support