Fixed bug in validation, which made library-upload on library admin page fail

namespaces
Pål Jørgensen 2014-09-05 14:12:46 +02:00 committed by Frode Petterson
parent 50b00e6459
commit 7cb2ebe17c
1 changed files with 2 additions and 1 deletions

View File

@ -609,9 +609,10 @@ class H5PValidator {
$missingLibraries = $this->getMissingLibraries($libraries);
foreach ($missingLibraries as $missing) {
if ($this->h5pF->getLibraryId($missing['machineName'], $missing['majorVersion'], $missing['minorVersion'])) {
unset($missingLibraries[$missing['machineName']]);
unset($missingLibraries[H5PCore::libraryToString($missing)]);
}
}
if (!empty($missingLibraries)) {
foreach ($missingLibraries as $library) {
$this->h5pF->setErrorMessage($this->h5pF->t('Missing required library @library', array('@library' => H5PCore::libraryToString($library))));