From 4c2cdbe2613da004c0f5736c2ee913ef17e983e4 Mon Sep 17 00:00:00 2001 From: Sara Arjona Date: Fri, 5 Jun 2020 08:58:28 +0200 Subject: [PATCH] MDL-68922 core_h5p: upgrade content with newer libraries The H5P editor always uses the latest libraries version. Besides, H5P has a mechanism for upgrading content created using older libraries. So, in order to be able to edit existing content created with older libraries, we can assume the library may change (for instance, from "Course presentation 1.20" to "Course presentation 1.22") because the $content->h5plibrary contains both (machinename and major/minor version). --- h5p/classes/editor.php | 4 ---- 1 file changed, 4 deletions(-) diff --git a/h5p/classes/editor.php b/h5p/classes/editor.php index eed37740cab..dfa171b2067 100644 --- a/h5p/classes/editor.php +++ b/h5p/classes/editor.php @@ -228,10 +228,6 @@ class editor { throw new coding_exception('Missing H5P library.'); } - if ($content->h5plibrary != $this->library) { - throw new coding_exception("Wrong H5P library."); - } - $content->params = $content->h5pparams; if (!empty($this->oldcontent)) {