HFP-1871 Fix missing variables
parent
d068b82ff5
commit
64e5ab4424
|
@ -1941,12 +1941,18 @@ class H5PCore {
|
|||
// Get latest version of MathDisplay library
|
||||
$libs = $this->h5pF->loadLibraries();
|
||||
$mathLibs = $libs['H5P.MathDisplay'];
|
||||
|
||||
$majorMax = '0';
|
||||
$minorMax = '0';
|
||||
foreach($mathLibs as $libVersion) {
|
||||
if ($libVersion->major_version === $majorMax && $libVersion->minor_version > $minorMax) {
|
||||
if ($libVersion->major_version === $majorMax && $libVersion->minor_version >= $minorMax) {
|
||||
$mathLib = $libVersion;
|
||||
$minorMax = $libVersion->minor_version;
|
||||
}
|
||||
else if ($libVersion->major_version > $majorMax) {
|
||||
$mathLib = $libVersion;
|
||||
$majorMax = $libVersion->major_version;
|
||||
$minorMax = $libVersion->minor_version;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue