raise error with versions older than Rails 4.1