@barchart/portfolio-api-common 1.2.36 → 1.2.37
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -267,13 +267,13 @@ module.exports = (() => {
|
|
|
267
267
|
}
|
|
268
268
|
|
|
269
269
|
const comparator = ComparatorBuilder.startWith((a, b) => {
|
|
270
|
-
return Day.compareDays(
|
|
270
|
+
return Day.compareDays(a.date, b.date);
|
|
271
271
|
}).thenBy((a, b) => {
|
|
272
272
|
return comparators.compareNumbers(getInstrumentTypePriority(a.instrument.type), getInstrumentTypePriority(b.instrument.type));
|
|
273
273
|
}).thenBy((a, b) => {
|
|
274
274
|
return comparators.compareStrings(a.instrument.id, b.instrument.id);
|
|
275
275
|
}).thenBy((a, b) => {
|
|
276
|
-
return comparators.compareNumbers(
|
|
276
|
+
return comparators.compareNumbers(a.sequence, b.sequence);
|
|
277
277
|
}).toComparator();
|
|
278
278
|
|
|
279
279
|
return TransactionFormatter;
|