From 7bc8666f309220a0eb93bca49aaa741bb013b26a Mon Sep 17 00:00:00 2001 From: Paal Joergensen Date: Thu, 15 Aug 2019 21:15:55 +0200 Subject: [PATCH] Don't invoke clearFilteredParameters for empty array --- h5p.classes.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/h5p.classes.php b/h5p.classes.php index d846884..c127185 100644 --- a/h5p.classes.php +++ b/h5p.classes.php @@ -1647,8 +1647,11 @@ class H5PStorage { $library_ids[] = $library['libraryId']; } + // Make sure libraries dependencies, parameter filtering and export files gets regenerated for all content who uses these libraries. - $this->h5pF->clearFilteredParameters($library_ids); + if (!empty($library_ids)) { + $this->h5pF->clearFilteredParameters($library_ids); + } // Tell the user what we've done. if ($newOnes && $oldOnes) {