Pad CRC strings to 8 characters.

Closes #290.
This commit is contained in:
Oliver Hamlet
2014-12-23 12:38:23 +00:00
parent 195964e411
commit 9798ce83e0
+2 -21
View File
@@ -109,7 +109,8 @@ function Plugin(obj) {
if (this.crc == 0) {
return '';
} else {
return this.crc.toString(16).toUpperCase();
/* Pad CRC string to 8 characters. */
return ('00000000' + this.crc.toString(16).toUpperCase()).slice(-8);
}
}
@@ -204,23 +205,3 @@ function jsonToPlugin(key, value) {
}
return value;
}