original_string: public function date(array $values)
      {
          if (count($values) != 1) {
              $vars = array('@field' => $this->translation->text('Condition'));
              return $this->translation->text('@field has invalid value', $vars);
          }
  
          $timestamp = strtotime(reset($values));
  
          if (empty($timestamp)) {
              $vars = array('@field' => $this->translation->text('Condition'));
              return $this->translation->text('@field has invalid value', $vars);
          }
  
          return true;
      }
code: public function date(array $values)
      {
          if (count($values) != 1) {
              $vars = array('@field' => $this->translation->text('Condition'));
              return $this->translation->text('@field has invalid value', $vars);
          }
  
          $timestamp = strtotime(reset($values));
  
          if (empty($timestamp)) {
              $vars = array('@field' => $this->translation->text('Condition'));
              return $this->translation->text('@field has invalid value', $vars);
          }
  
          return true;
      }
code_tokens: public function date ( array $ values ) { if ( count ( $ values ) != 1 ) { $ vars = array ( '@field' => $ this -> translation -> text ( 'Condition' ) ) ; return $ this -> translation -> text ( '@field has invalid value' , $ vars ) ; } $ timestamp = strtotime ( reset ( $ values ) ) ; if ( empty ( $ timestamp ) ) { $ vars = array ( '@field' => $ this -> translation -> text ( 'Condition' ) ) ; return $ this -> translation -> text ( '@field has invalid value' , $ vars ) ; } return true ; }
docstring: Validates the date condition
  @param array $values
  @return boolean|string
docstring_tokens: Validates the date condition