Skip to content

Commit 718cbb4

Browse files
committed
Merge pull request #4588 from learningequality/0.14.x
0.14.2
2 parents 39413a3 + 1d47b8d commit 718cbb4

File tree

3 files changed

+26
-5
lines changed

3 files changed

+26
-5
lines changed

data/version.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,18 @@
1+
0.14.2:
2+
release_date: "2015/10/02"
3+
git_commit: "dceccca"
4+
new_features:
5+
all: []
6+
students:
7+
coaches: []
8+
admins: []
9+
bugs_fixed:
10+
all:
11+
Properly compare language pack versions (#4587).
12+
students: []
13+
coaches: []
14+
admins: []
15+
116
0.14.1:
217
release_date: "2015/10/02"
318
git_commit: "0818d65"

kalite/updates/static/js/updates/update_languages.js

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,18 @@ var installed_languages = [];
33
var downloading = false;
44

55
function version_comparison(v1, v2) {
6-
// compare two version strings and return 1 if the first is higher than the second,
7-
// -1 if the first is lower than the second, and 0 if they are equal
6+
/*
7+
compare two version strings and return 1 if the first is higher than the second,
8+
-1 if the first is lower than the second, and 0 if they are equal.
9+
10+
:params v1, v2: Version strings expected format is either "N.N.N" or "N.N", where N is a positive integer.
11+
If both strings have the same format, they're compared using a lexical order.
12+
If one string is shorter than the other, then the other is truncated and then compared using lexical order.
13+
*/
814
var v1parts = v1.split('.'), v2parts = v2.split('.');
9-
var maxLen = Math.max(v1parts.length, v2parts.length);
15+
var minLen = Math.min(v1parts.length, v2parts.length);
1016
var part1, part2;
11-
for(var i = 0; i < maxLen; i++) {
17+
for(var i = 0; i < minLen; i++) {
1218
part1 = parseInt(v1parts[i], 10) || 0;
1319
part2 = parseInt(v2parts[i], 10) || 0;
1420
if (part1 > part2) return 1;

kalite/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
# Must also be of the form N.N.N for internal use, where N is a non-negative integer
88
MAJOR_VERSION = "0"
99
MINOR_VERSION = "14"
10-
PATCH_VERSION = "1"
10+
PATCH_VERSION = "2"
1111
VERSION = "%s.%s.%s" % (MAJOR_VERSION, MINOR_VERSION, PATCH_VERSION)
1212
SHORTVERSION = "%s.%s" % (MAJOR_VERSION, MINOR_VERSION)
1313

0 commit comments

Comments
 (0)