fix LengthHiding middleware for Rails 3.0