Skip to content

Commit f768468

Browse files
precizSteffenDE
authored andcommitted
Fix docs: allow_upload :writer expects a 3-arity anonymous function, not a module (#4181)
1 parent d07ea5a commit f768468

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

lib/phoenix_live_view.ex

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -846,10 +846,10 @@ defmodule Phoenix.LiveView do
846846
* `:auto_upload` - Instructs the client to upload the file automatically
847847
on file selection instead of waiting for form submits. Defaults to `false`.
848848
849-
* `:writer` - A module implementing the `Phoenix.LiveView.UploadWriter`
850-
behaviour to use for writing the uploaded chunks. Defaults to writing to a
851-
temporary file for consumption. See the `Phoenix.LiveView.UploadWriter` docs
852-
for custom usage.
849+
* `:writer` - A 3-arity anonymous function that returns a tuple with a module
850+
implementing the `Phoenix.LiveView.UploadWriter` behaviour and its options to use for
851+
writing the uploaded chunks. Defaults to writing to a temporary file for consumption.
852+
See the `Phoenix.LiveView.UploadWriter` docs for custom usage.
853853
854854
Raises when a previously allowed upload under the same name is still active.
855855

0 commit comments

Comments
 (0)