Rails3 compatibility