JS: Fix UInt160 comparison.

This commit is contained in:
Arthur Britto
2012-10-22 16:56:00 -07:00
committed by Stefan Thomas
parent c0eec780de
commit 45c54b6484
2 changed files with 10 additions and 2 deletions

View File

@@ -152,7 +152,7 @@ UInt160.prototype.copyTo = function(d) {
};
UInt160.prototype.equals = function(d) {
return this.value === d.value;
return isNaN(this.value) || isNaN(d.value) ? false : this.value.equals(d.value);
};
// value = NaN on error.