original_string: protected function validatePathFile()
      {
          $field = 'path';
          $value = $this->getSubmitted($field);
  
          if ($this->isExcluded($field) || $this->isError()) {
              return null;
          }
  
          if (!isset($value) && $this->isUpdating()) {
              return null;
          }
  
          $label = $this->translation->text('File');
  
          if (empty($value)) {
              $this->setErrorRequired($field, $label);
              return false;
          }
  
          if (!is_readable(gplcart_file_absolute($value))) {
              $this->setErrorUnavailable($field, $label);
              return false;
          }
  
          return true;
      }
code: protected function validatePathFile()
      {
          $field = 'path';
          $value = $this->getSubmitted($field);
  
          if ($this->isExcluded($field) || $this->isError()) {
              return null;
          }
  
          if (!isset($value) && $this->isUpdating()) {
              return null;
          }
  
          $label = $this->translation->text('File');
  
          if (empty($value)) {
              $this->setErrorRequired($field, $label);
              return false;
          }
  
          if (!is_readable(gplcart_file_absolute($value))) {
              $this->setErrorUnavailable($field, $label);
              return false;
          }
  
          return true;
      }
code_tokens: protected function validatePathFile ( ) { $ field = 'path' ; $ value = $ this -> getSubmitted ( $ field ) ; if ( $ this -> isExcluded ( $ field ) || $ this -> isError ( ) ) { return null ; } if ( ! isset ( $ value ) && $ this -> isUpdating ( ) ) { return null ; } $ label = $ this -> translation -> text ( 'File' ) ; if ( empty ( $ value ) ) { $ this -> setErrorRequired ( $ field , $ label ) ; return false ; } if ( ! is_readable ( gplcart_file_absolute ( $ value ) ) ) { $ this -> setErrorUnavailable ( $ field , $ label ) ; return false ; } return true ; }
docstring: Validates a file path
  @return boolean|null
docstring_tokens: Validates a file path