Support rails 4.2 and above.