Closed (fixed)
Project:
Advanced Form
Version:
2.0.x-dev
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
12 Jun 2025 at 04:13 UTC
Updated:
27 Nov 2025 at 22:39 UTC
Jump to comment: Most recent
Tests currently failing on 11.x - module needs to be compatible.
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
Comment #3
ericgsmith commentedReady for review.
Module was broken on 11.x after the NodeForm class has moved namespace: Drupal\node\NodeForm is now Drupal\node\Form\NodeForm
The CR doesn't seem to imply we should need to do anything for BC as the issue references the use of the deprecation class loader. However - autoloading does not apply when we are type checking - i.e when we do
instanceofit fails. And not fails like throws an error, it fails in that$form_object instanceof NodeFormevaluates toFALSE(as the class doesn't exist) and silently moves on.Calling
class_existswill trigger the autoloader and return to normal functionality (i.e allow this to work with 10.x and 11.x) but seeing as this is explicitly marked as an@internalclass we shouldn't be using it at all.Given all the logic was within an if statement that checked it was a node form, I've just changed to use the node form base form alter hook.
Comment #4
ericgsmith commented