Remove intermediate variables in Rails integration