patching for rails 4