Commit ee4a55fd authored by Robert Lyon's avatar Robert Lyon

Making sure empty $values parameter is sent as array() (Bug #1400514)

To test: checkout master - try and add a comment to a page on page
reload you should get an error

With patch - adding/viewing comments should work again

Change-Id: Ic32a5f7daf273385b745c57622abac369e388197
Signed-off-by: Robert Lyon's avatarRobert Lyon <robertl@catalyst.net.nz>
parent 2649e660
......@@ -1117,7 +1117,7 @@ abstract class ArtefactType implements IArtefactType {
FROM {artefact_attachment} aa
INNER JOIN {artefact} a ON aa.attachment = a.id
LEFT JOIN {artefact_file_files} f ON a.id = f.artefact
WHERE aa.artefact IN (' . join(', ', array_map('intval', $artefactids)) . ')', '');
WHERE aa.artefact IN (' . join(', ', array_map('intval', $artefactids)) . ')', array());
if (!$attachments) {
return array();
}
......
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