Commit 403fe723 authored by Richard Mansfield's avatar Richard Mansfield
Browse files

Fix for artefact comment upgrade (bug #636796)


Signed-off-by: default avatarRichard Mansfield <richard.mansfield@catalyst.net.nz>
parent 9fcc4392
......@@ -1570,6 +1570,15 @@ function xmldb_core_upgrade($oldversion=0) {
SELECT f.*, a.id AS artefactid, a.owner, a.group, a.institution
FROM {artefact_feedback} f JOIN {artefact} a ON f.artefact = a.id', array())) {
foreach ($artefactfeedback as &$f) {
if ($f->author > 0) {
$f->authorname = null;
}
else {
$f->author = null;
if (empty($f->authorname)) {
$f->authorname = '?';
}
}
$artefact = (object) array(
'artefacttype' => 'comment',
'owner' => $f->owner,
......
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