-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Restricting file upload types #35
Comments
This is a nice task and like @sanzeeb3 said on slack it is quite complex (but that's why I like it, thanks @cheh for pointing me to this plugin repo). I will try to handle it. I actually already started but as this is complex I don't want to do everything without consultation with the rest of you. (Also @slaFFik mentioned on slack we should, discuss it upon developing. So here is my plan as the list of the checkboxes (I will mark what I already done or started):
We're already storing in (I was also considering storing there only those native types which user will disable later, but I found it will be easier to incorporate currently available logic to handle it the way I described in previous paragraph)
It already displayed 'enabled' and 'custom' so this will be in par of what I described in previous point.
Same as we are removing other enabled file types.
And unchecked like the rest of available.
That's it. No more special logic. I am thinking also about small polishing:
I will be extending this comment as I find any culprits or additional things to change. |
I am not creating yet a merge request but here is the branch where I will be pushing commits. https://github.com/awesomemotive/file-upload-types/tree/fut/35-restricting-file-upload-types |
ok, status for now (currently in the branch above), I write ti down as a note to myself before short holidays:
what still must be done:
|
status update: now it left only to additionally add types to ennabled array during the migration and the fix will be ready |
PR is ready #49 |
A feature to restrict file upload types. Currently, the plugin can only allow additional file upload types.
Slack: https://awesomemotive.slack.com/archives/C2G5XRC9W/p1631056720207600
References:
https://www.wpbeginner.com/plugins/how-to-restrict-uploads-to-specified-file-types-only-in-wordpress/
https://wordpress.org/plugins/restrict-uploads/
The text was updated successfully, but these errors were encountered: