Skip to content

Commit

Permalink
Use logical assignment operator
Browse files Browse the repository at this point in the history
  • Loading branch information
XhmikosR committed Apr 2, 2024
1 parent 9a2be21 commit 5f4c9ae
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,10 @@ import osFilterObject from '@xhmikosr/os-filter-obj';
export default class BinWrapper {
constructor(options = {}) {
this.options = options;
this.options.strip ??= 1;

if (this.options.strip <= 0) {
this.options.strip = 0;
// eslint-disable-next-line logical-assignment-operators
} else if (!this.options.strip) {
this.options.strip = 1;
}
}

Expand Down

0 comments on commit 5f4c9ae

Please sign in to comment.