Commit 310b061d authored by Robert Lyon's avatar Robert Lyon
Browse files

Bug 1632863: Proper way to remove embedded image


Change-Id: I2fac457da7d58c8bd9cd14674931bfbecc3b530e
Signed-off-by: Robert Lyon's avatarRobert Lyon <>
parent b1c09465
......@@ -326,10 +326,9 @@ class ArtefactTypeAnnotation extends ArtefactType {
// Delete any embedded images for this annotation.
// Don't use EmbeddedImage::delete_embedded_images() - it deletes by
// the fileid. We need to delete by the resourceid.
delete_records('artefact_file_embedded', 'resourceid', $this->id);
// Remove any embedded images for this annotation.
EmbeddedImage::remove_embedded_images('annotation', $this->id);
delete_records('artefact_annotation', 'annotation', $this->id);
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