Problem/Motivation
When upgrading to Drupal 11.4 you receive a fatal error:
Fatal error: Type of Drupal\same_page_preview\Controller\PreviewPaneController::$formBuilder must be ?Drupal\Core\Form\FormBuilderInterface (as in class Drupal\node\Controller\NodePreviewController) in /app/web/modul
es/contrib/same_page_preview/src/Controller/PreviewPaneController.php on line 19Change in core is from: https://www.drupal.org/project/drupal/issues/3339905
Steps to reproduce
Install Same page Preview module 3.0.0-rc1 on Drupal 11.3.
Upgrade to Drupal 11.4.
Run database updates via drush and receive a fatal error message.
Proposed resolution
Change how property type is declared in class, and pass the formbuilder service to the parent controller (NodePreviewController).
Remaining tasks
Create mr.
Test on Drupal 11.3
Test on Drupal 11.4
Test doing Drupal 11.3 - Drupal 11.4 upgrade.
User interface changes
None.
API changes
None.
Data model changes
None.
| Comment | File | Size | Author |
|---|---|---|---|
| #8 | 3608134_drupal_11_4_compatibility.patch | 1.23 KB | linichalexey |
Issue fork same_page_preview-3608134
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
Comment #2
jefflogan commentedI've tested on Drupal 11.3
I've Test on Drupal 11.4.0
And tested doing Drupal 11.3 - Drupal 11.4 upgrade.
Therefore these needs further review/testing, and then merging.
Comment #4
nicxvan commentedThis worked for me as well on 2.1
Comment #5
cosmicdreams commentedagreed. merging.
Comment #6
cosmicdreams commentedComment #8
linichalexey commentedIf you landed here while updating to Drupal 11.4 and using same_page_preview v2.1, not 3.0.x, here is the patch rebased from the PR in that issue.