Reviewed & tested by the community
Project:
Entity Browser
Version:
8.x-2.x-dev
Component:
Widget plugins
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
2 Apr 2026 at 22:14 UTC
Updated:
10 Apr 2026 at 14:36 UTC
Jump to comment: Most recent
Comments
Comment #2
aayushpathak commentedworking..
Comment #4
aayushpathak commentedInjected the image factory service so that supported extensions are resolved dynamically from the active image toolkit, rather than being limited to a hardcoded list. This allows any image format supported by the toolkit to be accepted.
Comment #5
benstallings commentedClaude Code says:
Assessment — Good change, with minor notes:
1. Correctness: The approach is sound. This mirrors how Drupal core's own ImageWidget handles extensions — delegating to the toolkit rather than maintaining a static list.
2. Service injection: Properly done via the create() method with a new $imageFactory property and docblock. Follows the existing pattern used for $mimeTypeGuesser.
3. Potential concern: ImageFactory::getSupportedExtensions() was added in Drupal 10.3. The module's .info.yml requires ^10.2 || ^11. If you want to support 10.2, this would need a version check or the minimum core version should be bumped. If 10.2 support has effectively been dropped, this is fine as-is.
4. Commit message style: Minor — the commit message has no space after Issue (Issue#3582928 vs Issue #3582928), inconsistent with the project's convention.
5. No test coverage for this change, but it's a straightforward service swap and would be hard to unit test without a toolkit mock.
Overall, this is a clean, well-scoped fix. The main decision point is whether the Drupal 10.2 compatibility matters.
Comment #6
benstallings commentednote that the failing tests are not related to this branch; those tests all fail on the release branch.