Commit 5e048a10 authored by Nigel McNie's avatar Nigel McNie Committed by Nigel McNie
Browse files

Added support for checking file elements.

parent edd262fb
......@@ -27,7 +27,7 @@
defined('INTERNAL') || die();
function form_rule_required($field) {
if ($field == '') {
if ($field == '' || is_array($field) && !empty($field['error'])) {
return get_string('This field is required');
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment