You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The mimeType "text/csv" looks like it isnt supported by payload I try to upload .csv files but i get an mimeType error
Even got the same thing for .xml files ( "application/xml" )
Image works fine, same for pdf, but not for xml .csv
Reproduction Steps
You have to create a collection, upload field then mimeTypes inside with "application/xml" or "text/csv",
The provided mimetype in mimeTypes was actually not correct. To see the actual mimetype that is detected, remove the mimeTypes field, upload file, and look at the API response - adjust mimeTypes list accordingly.
Link to reproduction
No response
Payload Version
V3.beta35
Node Version
20.5.1
Next.js Version
[email protected]
Describe the Bug
The mimeType "text/csv" looks like it isnt supported by payload I try to upload .csv files but i get an mimeType error

Even got the same thing for .xml files ( "application/xml" )
Image works fine, same for pdf, but not for xml .csv
Reproduction Steps
You have to create a collection, upload field then mimeTypes inside with "application/xml" or "text/csv",
here is the full code
import { CollectionConfig } from "payload/types";
export const Documents: CollectionConfig = {
slug: "documents",
admin: {
useAsTitle: "filename",
},
access: {
read: () => true,
},
upload: {
staticURL: "/documents",
staticDir: "documents",
mimeTypes: ["application/xml"],
},
fields: [{ name: "alt", label: "Alt", type: "text", required: false }],
};
export default Documents;
Adapters and Plugins
no plugins
The text was updated successfully, but these errors were encountered: