title: Multiple Filter Methods
body: <p>I'm trying to solve this problem.
  I'm creating a filter method, that has to return me a filtered array based on my preference.
  The array is containing some sports bet info, like the odd quote, the starting date, the name of the bookmaker, etc, and I'm trying (for the moment) to just filter based on the min and max odds</p>
  <p>First of all, into my &quot;Parent&quot; react component, I receive some info from his child, and those info are stored in an object.</p>
  <p>The object is like that:</p>
  <pre><code>filters = {minOdd: &quot;&quot;, maxOdds:&quot;&quot;, ecc...}
   
  </code></pre>
  <p>And the filter method is like:</p>
  <pre><code>setFilters = () =&gt; {
          const odds = this.state.odds
          const filters = this.state.filters
  
          const newOdds = odds.filter((odd) =&gt; odd.quota &gt; filters.quotaMin)
          .filter((odd) =&gt; odd.quota &lt; filters.quotaMax)
      }
  </code></pre>
  <p>Where &quot;quota&quot; means &quot;odd&quot;, quotaMin means &quot;min odd&quot; and &quot;quotaMax&quot; means max odd</p>
  <p>Now, if I set the min and the max odd into my child component, the function returns me an array containing all the right odds. But if I set just one of the 2 filters, this function returns me back an empty object.</p>
  <p>I'n my opinion, the problem is that if i don't set one of the 2 value, the filter method compares the odd this a value that is like modd.quota &lt; filters.quotaMax, where filters.quotaMax could be = to &quot;&quot;.
  Soo i have to not allow the filter method to filter value that are = to &quot;&quot;.</p>
  <p>If someone can give my an advice!
  Thanks in advice!</p>