Sha256: dbd9bc60489214565b4c9ee3ff69c25f52c9126491c93163f13e848a30b64cec
Contents?: true
Size: 529 Bytes
Versions: 109
Compression:
Stored size: 529 Bytes
Contents
module ZuoraConnect class BadMultipartFormDataSanitizer def initialize(app) @app = app end def call(env) if env['CONTENT_TYPE'] =~ /multipart\/form-data/ begin Rack::Multipart.parse_multipart(env) rescue EOFError => ex # set content-type to multipart/form-data without the boundary part # to handle the case where empty content is submitted env['CONTENT_TYPE'] = 'multipart/form-data' end end @app.call(env) end end end
Version data entries
109 entries across 109 versions & 1 rubygems