@barchart/portfolio-api-common 1.0.55 → 1.0.56
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.
|
@@ -137,13 +137,13 @@ module.exports = (() => {
|
|
|
137
137
|
|
|
138
138
|
setPrice(symbol, price) {
|
|
139
139
|
if (this._symbols.hasOwnProperty(symbol)) {
|
|
140
|
-
this._symbols.forEach(item.setPrice(price));
|
|
140
|
+
this._symbols.forEach(item => item.setPrice(price));
|
|
141
141
|
}
|
|
142
142
|
}
|
|
143
143
|
|
|
144
144
|
getGroup(keys) {
|
|
145
145
|
const node = keys.reduce((tree, key) => {
|
|
146
|
-
tree = tree.findChild(
|
|
146
|
+
tree = tree.findChild(group => group.description === key);
|
|
147
147
|
|
|
148
148
|
return tree;
|
|
149
149
|
}, this._tree);
|
|
@@ -153,7 +153,7 @@ module.exports = (() => {
|
|
|
153
153
|
|
|
154
154
|
getGroups(keys) {
|
|
155
155
|
const node = keys.reduce((tree, key) => {
|
|
156
|
-
tree = tree.findChild(
|
|
156
|
+
tree = tree.findChild(group => group.description === key);
|
|
157
157
|
|
|
158
158
|
return tree;
|
|
159
159
|
}, this._tree);
|
package/package.json
CHANGED
package/test/SpecRunner.js
CHANGED
|
@@ -652,13 +652,13 @@ module.exports = (() => {
|
|
|
652
652
|
|
|
653
653
|
setPrice(symbol, price) {
|
|
654
654
|
if (this._symbols.hasOwnProperty(symbol)) {
|
|
655
|
-
this._symbols.forEach(item.setPrice(price));
|
|
655
|
+
this._symbols.forEach(item => item.setPrice(price));
|
|
656
656
|
}
|
|
657
657
|
}
|
|
658
658
|
|
|
659
659
|
getGroup(keys) {
|
|
660
660
|
const node = keys.reduce((tree, key) => {
|
|
661
|
-
tree = tree.findChild(
|
|
661
|
+
tree = tree.findChild(group => group.description === key);
|
|
662
662
|
|
|
663
663
|
return tree;
|
|
664
664
|
}, this._tree);
|
|
@@ -668,7 +668,7 @@ module.exports = (() => {
|
|
|
668
668
|
|
|
669
669
|
getGroups(keys) {
|
|
670
670
|
const node = keys.reduce((tree, key) => {
|
|
671
|
-
tree = tree.findChild(
|
|
671
|
+
tree = tree.findChild(group => group.description === key);
|
|
672
672
|
|
|
673
673
|
return tree;
|
|
674
674
|
}, this._tree);
|