Catch withMedia
and withFiles
to prevent uploads in Production
#528
Labels
withMedia
and withFiles
to prevent uploads in Production
#528
In #456 we were talking about preventing the uploads in a more general way. Pedro came up with this solution and I like it:
We can catch the
withMedia
andwithFiles
, with that we prevent the uploader events from beeing registered, so we wouldn't even need to bind into the uploader classes as they wouldn't be registered/called.That wouldn't prevent much, just the upload from happening, but anything you submit in the input would be saved to the database, except it didn't go through the upload process.
At the moment we can't bind to our uploaders as they aren't resolved from the container, they are statically initialized.
We can work that out, or use the mutator as we are doing now. Everything is "working", except we always send empty values to the uploaders 🤷
Probably it's like you said, it's more future proof, but at the moment it's not a requirement.
Originally posted by @pxpm in #456 (comment)
The text was updated successfully, but these errors were encountered: