elixir-plug / plug

Compose web applications with functions
https://hex.pm/packages/plug
Other
2.84k stars 582 forks source link

Fix example for Plug.Parsers.MULTIPART dynamic configuration #1113

Closed edgurgel closed 2 years ago

edgurgel commented 2 years ago

Plug.Parsers.MULTIPART expects a number as length. The following error is raised if a binary is passed:

** (Plug.Parsers.ParseError) malformed request, a ArithmeticError exception was raised with message "bad argument in arithmetic expression"
    :erlang.-("100000000", 1142962)
josevalim commented 2 years ago

:green_heart: :blue_heart: :purple_heart: :yellow_heart: :heart: