Skip to content

Commit

Permalink
Don't invoke clearFilteredParameters for empty array
Browse files Browse the repository at this point in the history
  • Loading branch information
fnoks committed Aug 15, 2019
1 parent 8ceb77e commit 7bc8666
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion h5p.classes.php
Original file line number Diff line number Diff line change
Expand Up @@ -1647,8 +1647,11 @@ private function saveLibraries() {

$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) {
Expand Down

0 comments on commit 7bc8666

Please sign in to comment.