Fix many Rails 3->4 deprecations regarding using lambda scopes