original_string: protected function setDataEditTrigger()
      {
          $conditions = $this->getData('trigger.data.conditions');
  
          if (empty($conditions) || !is_array($conditions)) {
              return null;
          }
  
          if (!$this->isError()) {
              gplcart_array_sort($conditions);
          }
  
          $modified = array();
  
          foreach ($conditions as $condition) {
              $modified[] = is_string($condition) ? $condition : $condition['original'];
          }
  
          $this->setData('trigger.data.conditions', implode("\n", $modified));
      }
code: protected function setDataEditTrigger()
      {
          $conditions = $this->getData('trigger.data.conditions');
  
          if (empty($conditions) || !is_array($conditions)) {
              return null;
          }
  
          if (!$this->isError()) {
              gplcart_array_sort($conditions);
          }
  
          $modified = array();
  
          foreach ($conditions as $condition) {
              $modified[] = is_string($condition) ? $condition : $condition['original'];
          }
  
          $this->setData('trigger.data.conditions', implode("\n", $modified));
      }
code_tokens: protected function setDataEditTrigger ( ) { $ conditions = $ this -> getData ( 'trigger.data.conditions' ) ; if ( empty ( $ conditions ) || ! is_array ( $ conditions ) ) { return null ; } if ( ! $ this -> isError ( ) ) { gplcart_array_sort ( $ conditions ) ; } $ modified = array ( ) ; foreach ( $ conditions as $ condition ) { $ modified [ ] = is_string ( $ condition ) ? $ condition : $ condition [ 'original' ] ; } $ this -> setData ( 'trigger.data.conditions' , implode ( "\n" , $ modified ) ) ; }
docstring: Converts an array of conditions into a multiline string
docstring_tokens: Converts an array of conditions into a multiline string