Getting error when enable processors for File attachments.

Error: Call to undefined method Drupal\search_api_attachments\Plugin\search_api\processor\FilesExtrator::getExcludedMimes() in Drupal\search_api_attachments\Plugin\search_api\processor\FilesExtrator->submitConfigurationForm()

Solution:

Calling undefined method in search_api_attachments\src\Plugin\search_api\processor\FilesExtrator.php file. Please use the below code

$excluded_mimes_array = $this->extractFileValidator->getExcludedMimes($excluded_extensions_array);

instead of

$excluded_mimes_array = $this->getExcludedMimes($excluded_extensions_array);

CommentFileSizeAuthor
#2 filesextrator-2965947-2.patch954 bytesrovo

Comments

selvakumar created an issue. See original summary.

rovo’s picture

Status: Active » Needs review
StatusFileSize
new954 bytes

Thank you Selvakumar! That fixed it for me too.

I created a patch from your suggestion.

mkalkbrenner’s picture

Status: Needs review » Reviewed & tested by the community

patch works for me

izus’s picture

Thanks for the patch

  • rovo authored 6d03f93 on 8.x-1.x
    Issue #2965947 by rovo, selvakumar, mkalkbrenner, izus: Getting error...
izus’s picture

Status: Reviewed & tested by the community » Fixed

Thanks all
this is now merged

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.