original_string: public static function check(ComponentBase $component, $fileName)
      {
          $partial = new static($component);
          $filePath = $partial->getFilePath($fileName);
          if (!strlen(File::extension($filePath))) {
              $filePath .= '.'.$partial->getDefaultExtension();
          }
  
          return File::isFile($filePath);
      }
code: public static function check(ComponentBase $component, $fileName)
      {
          $partial = new static($component);
          $filePath = $partial->getFilePath($fileName);
          if (!strlen(File::extension($filePath))) {
              $filePath .= '.'.$partial->getDefaultExtension();
          }
  
          return File::isFile($filePath);
      }
code_tokens: public static function check ( ComponentBase $ component , $ fileName ) { $ partial = new static ( $ component ) ; $ filePath = $ partial -> getFilePath ( $ fileName ) ; if ( ! strlen ( File :: extension ( $ filePath ) ) ) { $ filePath .= '.' . $ partial -> getDefaultExtension ( ) ; } return File :: isFile ( $ filePath ) ; }
docstring: Returns true if the specific component contains a matching partial.
  @param \Cms\Classes\ComponentBase $component Specifies a component the file belongs to.
  @param string $fileName Specifies the file name to check.
  @return bool
docstring_tokens: Returns true if the specific component contains a matching partial .