Problem/Motivation
Click 'Add' on the link composite element first throws the below error.
Warning: array_flip(): Can only flip STRING and INTEGER values! in Drupal\Core\Entity\EntityStorageBase->loadMultiple() (line 227 of /private/var/www/sites/d8_webform/core/lib/Drupal/Core/Entity/EntityStorageBase.php) #0 /private/var/www/sites/d8_webform/core/includes/bootstrap.inc(566): _drupal_error_handler_real(2, 'array_flip(): C...', '/private/var/ww...', 227, Array) #1 [internal function]: _drupal_error_handler(2, 'array_flip(): C...', '/private/var/ww...', 227, Array) #2 /private/var/www/sites/d8_webform/core/lib/Drupal/Core/Entity/EntityStorageBase.php(227): array_flip(Array) #3 /private/var/www/sites/d8_webform/modules/sandbox/webform/src/Plugin/WebformElement/EntityAutocomplete.php(50): Drupal\Core\Entity\EntityStorageBase->loadMultiple(Array) #4 /private/var/www/sites/d8_webform/modules/sandbox/webform/src/Element/WebformMultiple.php(566): Drupal\webform\Plugin\WebformElement\EntityAutocomplete->setDefaultValue(Array) #5 /private/var/www/sites/d8_webform/modules/sandbox/webform/src/Element/WebformMultiple.php(389): Drupal\webform\Element\WebformMultiple::setElementDefaultValue(Array, Array) #6
Proposed resolution
Determine why the error is being thrown and fix it.
Comment | File | Size | Author |
---|---|---|---|
#5 | 2931222-5.patch | 3.4 KB | jrockowitz |
| |||
#3 | 2931222-3.patch | 465 bytes | jrockowitz |
#2 | webform.webform.issue_2931222.yml | 3.3 KB | jrockowitz |
#2 | Issue 2931222 Error being thrown by multiple entity autocomplete with multiple composite Webform Demo Site.png | 183.82 KB | jrockowitz |
Comments
Comment #2
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedComment #3
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedComment #5
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commentedComment #6
jrockowitz CreditAttribution: jrockowitz as a volunteer and at The Big Blue House commented