MDL-15666 - change all the portfolio plugins and callers to use exceptions
rather than relying on return values (send_package and prepare_package) move zipping of temporary files into the exporter class so it can be overridden during unit tests fix a small todo in mahara plugin
This commit is contained in:
@@ -3200,7 +3200,6 @@ class assignment_portfolio_caller extends portfolio_module_caller_base {
|
||||
foreach ($this->files as $file) {
|
||||
$this->exporter->copy_existing_file($file);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
public function get_sha1() {
|
||||
|
||||
@@ -275,7 +275,7 @@ class assignment_online extends assignment_base {
|
||||
|
||||
function portfolio_prepare_package($exporter, $userid=0) {
|
||||
$submission = $this->get_submission($userid);
|
||||
return $exporter->write_new_file(format_text($submission->data1, $submission->data2), 'assignment.html');
|
||||
$exporter->write_new_file(format_text($submission->data1, $submission->data2), 'assignment.html');
|
||||
}
|
||||
|
||||
function portfolio_supported_formats() {
|
||||
|
||||
Reference in New Issue
Block a user