Migrate to rails 4