Fix equals NumberVersion

This commit is contained in:
Ezequiel-Vega 2022-03-22 15:51:47 -03:00
parent a4febe347b
commit 5efcdb45ff

View File

@ -44,17 +44,11 @@ export default class VersionNumber {
} }
public equals<T>(o: T): boolean { public equals<T>(o: T): boolean {
if (o instanceof VersionNumber) {
return true;
}
if (!(o instanceof VersionNumber)) { if (!(o instanceof VersionNumber)) {
return false; return false;
} }
const versionNumber: VersionNumber = o as VersionNumber; const versionNumber: VersionNumber = o as VersionNumber;
return this.version === versionNumber.version;
return !(this.version ? this.version !== versionNumber.version : versionNumber.version);
} }
private getTokinizer(): Array<string> { private getTokinizer(): Array<string> {