Commit d77fcb12 authored by Aaron Wells's avatar Aaron Wells

Bug 1606432: Use safe_require to make sure PluginArtefact is loaded

Change-Id: I2e047be4ecad4594b9d27bb6d0058fa5971966ce
behatnotneeded: Test to come later
parent 2c262cdf
......@@ -399,7 +399,7 @@ function edituser_site_submit(Pieform $form, $values) {
}
$notified = get_field('usr_account_preference', 'value', 'field', 'quota_exceeded_notified', 'usr', $user->id);
if ($overlimit && '1' !== $notified) {
require_once(get_config('docroot') . 'artefact/file/lib.php');
safe_require('artefact', 'file');
ArtefactTypeFile::notify_users_threshold_exceeded(array($user), false);
// no need to email admin as we can alert them right now
$SESSION->add_error_msg(get_string('useroverquotathreshold', 'artefact.file', display_name($user)));
......
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