Skip to content

Commit 771f8c9

Browse files
committed
Fix bug with Series or comparison
1 parent e01d8b9 commit 771f8c9

File tree

4 files changed

+463
-306
lines changed

4 files changed

+463
-306
lines changed

danfojs-browser/src/core/series.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1313,7 +1313,7 @@ export default class Series extends NDframe {
13131313
const newValues = [];
13141314

13151315
this.values.forEach((val, i) => {
1316-
newValues.push(Boolean(val) | (other.values[i]));
1316+
newValues.push(Boolean(val) || (other.values[i]));
13171317
});
13181318

13191319
return new Series(newValues, {
@@ -1323,7 +1323,7 @@ export default class Series extends NDframe {
13231323
const newValues = [];
13241324

13251325
this.values.forEach((val) => {
1326-
newValues.push(Boolean(val) | (other));
1326+
newValues.push(Boolean(val) || (other));
13271327
});
13281328

13291329
return new Series(newValues, {
@@ -1333,7 +1333,7 @@ export default class Series extends NDframe {
13331333
const newValues = [];
13341334

13351335
this.values.forEach((val, i) => {
1336-
newValues.push(Boolean(val) | (other[i]));
1336+
newValues.push(Boolean(val) || (other[i]));
13371337
});
13381338

13391339
return new Series(newValues, {

0 commit comments

Comments
 (0)