Use numbers when comparing versions
parent
cdfab4d4b6
commit
0c5971d6d4
|
@ -100,6 +100,7 @@ H5P.ContentUpgradeProcess = (function (Version) {
|
|||
else {
|
||||
// Go through the minor versions for this major version
|
||||
asyncSerial(minors, function (minor, upgrade, nextMinor) {
|
||||
minor =+ minor;
|
||||
if (minor <= oldVersion.minor || minor > newVersion.minor) {
|
||||
// Older than or equal to the current version or newer than the selected
|
||||
nextMinor();
|
||||
|
|
|
@ -10,8 +10,8 @@ H5P.Version = (function () {
|
|||
var versionSplit = version.split('.', 3);
|
||||
|
||||
// Public
|
||||
this.major = versionSplit[0];
|
||||
this.minor = versionSplit[1];
|
||||
this.major =+ versionSplit[0];
|
||||
this.minor =+ versionSplit[1];
|
||||
|
||||
/**
|
||||
* Public. Custom string for this object.
|
||||
|
|
Loading…
Reference in New Issue