making rails 4.0 compatible