some fixes with rails 4 rc1