US3 Upgrade to rails 4.

Changed code that caused deprecation warnings.

Update gems to be rails 4 compat.

Went through rails 3.2.x -> 4.0 upgrade page.