title: Set value in array PHP
body: <p>I have an multidimensional array with objects. If the object has status 1 or 2 and the color is not green, I want to set color to blue. How can I do that?</p>
  
  <pre><code>foreach ($objects as $obj) {
      if (in_array($obj['status'], [1,2] )) {
          if ($obj['color'] != 'green'){
              //set color to blue
          }
      }
  }
  </code></pre>