fix in rails 4