original_string: public function source($dir)
      {
          // Check if unbuilt Drupal
          foreach ($this->getMakefiles($dir) as $file) {
              $f = fopen($file, 'r');
              $peek = fread($f, 1000);
              fclose($f);
              if (strpos($peek, 'api') !== FALSE && strpos($peek, 'core') !== FALSE) {
                  return true;
              }
          }
  
          return false;
      }
code: public function source($dir)
      {
          // Check if unbuilt Drupal
          foreach ($this->getMakefiles($dir) as $file) {
              $f = fopen($file, 'r');
              $peek = fread($f, 1000);
              fclose($f);
              if (strpos($peek, 'api') !== FALSE && strpos($peek, 'core') !== FALSE) {
                  return true;
              }
          }
  
          return false;
      }
code_tokens: public function source ( $ dir ) { // Check if unbuilt Drupal foreach ( $ this -> getMakefiles ( $ dir ) as $ file ) { $ f = fopen ( $ file , 'r' ) ; $ peek = fread ( $ f , 1000 ) ; fclose ( $ f ) ; if ( strpos ( $ peek , 'api' ) !== FALSE && strpos ( $ peek , 'core' ) !== FALSE ) { return true ; } } return false ; }
docstring: Checks if Drupal project, but source.
  
  @param $dir
  
  @return bool
docstring_tokens: Checks if Drupal project but source .