make work with rails4