Problem/Motivation

After applying a patch from https://www.drupal.org/project/acquia_connector/issues/3330332, in case local credentials are not set (acquia_identifier, acquia_key, acquia_application_uuid variables), when we try to visit the cofiguration page (admin/config), then we get following error:

TypeError: Argument 1 passed to Drupal\acquia_search\AcquiaSearchSolrMessages::getNoPreferredIndexError() must be of the type array, null given, called in /mnt/www/html/jnjnab5d1cdev/docroot/profiles/jjbos/modules/contrib/acquia_connector/acquia_search/src/v3/AcquiaSearchSolrApi.php on line 120 in Drupal\acquia_search\AcquiaSearchSolrMessages::getNoPreferredIndexError() (line 93 of /mnt/www/html/jnjnab5d1cdev/docroot/profiles/jjbos/modules/contrib/acquia_connector/acquia_search/src/AcquiaSearchMessages.php).
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

yurikulinkovich created an issue. See original summary.

mglaman’s picture

I see: return array_keys($this->availableCores);. The property availableCores is null by default.

alena_stanul made their first commit to this issue’s fork.

alena_stanul’s picture

Status: Active » Needs review
driverok’s picture

MR!29 looks good to me.
After applying the above MR, there is no error, mentioned in the description.
Thanks Alena!

renat33’s picture

Hello,

I've checked the issue with the fix from @alena_stanul. There is no error on 'admin/config' page after the fix.

japerry’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

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