Entity browser JS error on submit selection

Created on 30 November 2023, 12 months ago
Updated 6 March 2024, 9 months ago

Problem/Motivation

I'm not familiar with the entity_browser.modal_select.js library so I'm not sure what it does. Since this library is getting added as a dependency of entity browser's library, it's not checking for instances where mercury isn't actually being used.

Steps to reproduce

  • Content type with a taxonomy reference field
  • Entity browser widget setup
  • Mercury editor is not used and is disabled for this current entity type

JS Error:
Uncaught TypeError: Cannot read properties of null (reading 'close')

Proposed resolution

I have a patch to at least check if that element exists before closing it. I haven't tested this on the scenario for which it was originally intended, so that needs to be done.

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

RTBC

Version

2.1

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States asherry

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @asherry
  • Status changed to Needs review 12 months ago
  • πŸ‡ΊπŸ‡ΈUnited States asherry
  • Issue was unassigned.
  • πŸ‡ΊπŸ‡ΈUnited States asherry
  • πŸ‡ΊπŸ‡ΈUnited States nwoodland

    I encountered this same issue, and the patch in #2 fixes the problem without causing issues when using entity browser in ME context. Thanks Alan!

    I happen to work on a system that also has a separate patch for issue #3401444 applied, so I needed to re-roll this patch to work with that patch. I'm attaching that re-rolled patch here in case anyone else is in the same boat, or if the #3401444 patch gets merged first (but, again, people should use the patch from #2 otherwise).

  • Status changed to RTBC 9 months ago
  • πŸ‡ΊπŸ‡ΈUnited States nwoodland
Production build 0.71.5 2024