More tweaks for Rails4.