original_string: protected function makeSearchableFields(Collection $fields = null, $tableName)
      {
          if (is_null($fields))
          {
              return '';
          }
  
          $searchables = [];
  
          foreach ($fields as $field)
          {
              if (intval($field->search_priority) > 0)
              {
                  $searchables[] = "'{$tableName}.{$field->name}' => {$field->search_priority}";
              }
          }
  
          return implode(",", $searchables);
      }
code: protected function makeSearchableFields(Collection $fields = null, $tableName)
      {
          if (is_null($fields))
          {
              return '';
          }
  
          $searchables = [];
  
          foreach ($fields as $field)
          {
              if (intval($field->search_priority) > 0)
              {
                  $searchables[] = "'{$tableName}.{$field->name}' => {$field->search_priority}";
              }
          }
  
          return implode(",", $searchables);
      }
code_tokens: protected function makeSearchableFields ( Collection $ fields = null , $ tableName ) { if ( is_null ( $ fields ) ) { return '' ; } $ searchables = [ ] ; foreach ( $ fields as $ field ) { if ( intval ( $ field -> search_priority ) > 0 ) { $ searchables [ ] = "'{$tableName}.{$field->name}' => {$field->search_priority}" ; } } return implode ( "," , $ searchables ) ; }
docstring: Makes searchable fields
  
  @param Collection $fields
  @param string $tableName
  @return string
docstring_tokens: Makes searchable fields