title: Laravel filter array based on element value
body: <p>I have the following array that I need to filter it and get just the elements which have <code>type = 1</code></p>
  
  <pre><code>array:5 [
    0 =&gt; array:3 [
      "id" =&gt; 1
      "name" =&gt; "Agua Corriente"
      "type" =&gt; 1
    ]
    1 =&gt; array:3 [
      "id" =&gt; 2
      "name" =&gt; "Cloaca"
      "type" =&gt; 1
    ]
    2 =&gt; array:3 [
      "id" =&gt; 3
      "name" =&gt; "Gas Natural"
      "type" =&gt; 2
    ]
    3 =&gt; array:3 [
      "id" =&gt; 4
      "name" =&gt; "Internet"
      "type" =&gt; 3
    ]
    4 =&gt; array:3 [
      "id" =&gt; 5
      "name" =&gt; "Electricidad"
      "type" =&gt; 3
    ]
  ]
  </code></pre>
  
  <p>This is the expected result:</p>
  
  <pre><code>array:2 [
    0 =&gt; array:3 [
      "id" =&gt; 1
      "name" =&gt; "Agua Corriente"
      "type" =&gt; 1
    ]
    1 =&gt; array:3 [
      "id" =&gt; 2
      "name" =&gt; "Cloaca"
      "type" =&gt; 1
    ]
  ]
  </code></pre>
  
  <p>I'm trying to solve it with <code>Arr::where</code> helper but I'm not getting the expected result.
  Does anyone can help me?</p>
  
  <p>Regards</p>