[AMOS commit] MDL-50794 workshop: Improve the file type restricting implementation Committed into Git: 2016-02-24 15:49 UTC

[AMOS commit] MDL-50794 workshop: Improve the file type restricting implementation Committed into Git: 2016-02-24 15:49 UTC

by AMOS bot -
Number of replies: 0
Author: David Mudrák
MDL-50794 workshop: Improve the file type restricting implementation
This is basically a clean up and what I think improved version of the
original Mahmoud's patch.

The actual checking for allowed file extensions has been re-implemented
and is now covered by unit tests. The list of allowed extensions is now
also assed to the filemanager element's accepted_types option to prevent
picking other files (we still need the in-place validation though). The
form validation is simplified a bit. The custom validation of file size
introduced in the previous patch has been removed as not related to this
issue (also I believe it should not be done at this level).


http://git.moodle.org/gw?p=moodle.git;a=commit;h=996f7e8228f7547ad006ceb1489d3f841bb00433
http://github.com/moodle/moodle/commit/996f7e8228f7547ad006ceb1489d3f841bb00433

+ 3.1 en [allowedfiletypesforoverallfeedback_help,mod_workshop]
+ 3.1 en [allowedfiletypesforoverallfeedback_link,mod_workshop]
+ 3.1 en [allowedfiletypesforsubmission_help,mod_workshop]
+ 3.1 en [allowedfiletypesforsubmission_link,mod_workshop]
+ 3.1 en [err_unknownfileextension,mod_workshop]
+ 3.1 en [err_wrongfileextension,mod_workshop]
- 3.1 en [err_maxbytes,mod_workshop]
- 3.1 en [err_notallowedfiletype,mod_workshop]