Use content_length method instead of ENV['CONTENT_LENGTH'].to_i