Skip to content

fix (post): uploading plain text files#302

Open
alphashuro wants to merge 1 commit into
tomaka:masterfrom
alphashuro:fix-uploading-text-files
Open

fix (post): uploading plain text files#302
alphashuro wants to merge 1 commit into
tomaka:masterfrom
alphashuro:fix-uploading-text-files

Conversation

@alphashuro

Copy link
Copy Markdown

closes #291

We were using mutipart_field.is_text() to branch between parsing it as a text field vs a file, but text files pass this check and then subsequently fail to parse as a text field (rightly so).

This change checks for the existence of a filename instead to decide whether to parse the field as a file or text field.

closes tomaka#291

We were using `mutipart_field.is_text()` to branch between parsing it as
a text field vs a file, but text files pass this check and then
subsequently fail to parse as a text field (rightly so).

This change checks for the existence of a filename instead to decide
whether to parse the field as a file or text field.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Cannot upload plain/text (*.txt) files with rouille::input::post::BufferedFile

1 participant