File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -85,9 +85,9 @@ function priceRanges({
85
85
86
86
refinements . forEach ( v => {
87
87
if ( v . operator . indexOf ( '>' ) !== - 1 ) {
88
- from = v . value [ 0 ] + 1 ;
88
+ from = Math . floor ( v . value [ 0 ] ) ;
89
89
} else if ( v . operator . indexOf ( '<' ) !== - 1 ) {
90
- to = v . value [ 0 ] - 1 ;
90
+ to = Math . ceil ( v . value [ 0 ] ) ;
91
91
}
92
92
} ) ;
93
93
return [ { from, to, isRefined : true } ] ;
@@ -99,10 +99,10 @@ function priceRanges({
99
99
helper . clearRefinements ( attributeName ) ;
100
100
if ( facetValues . length === 0 || facetValues [ 0 ] . from !== from || facetValues [ 0 ] . to !== to ) {
101
101
if ( typeof from !== 'undefined' ) {
102
- helper . addNumericRefinement ( attributeName , '>' , from - 1 ) ;
102
+ helper . addNumericRefinement ( attributeName , '>= ' , Math . floor ( from ) ) ;
103
103
}
104
104
if ( typeof to !== 'undefined' ) {
105
- helper . addNumericRefinement ( attributeName , '<' , to + 1 ) ;
105
+ helper . addNumericRefinement ( attributeName , '<= ' , Math . ceil ( to ) ) ;
106
106
}
107
107
}
108
108
You can’t perform that action at this time.
0 commit comments