Problem/Motivation
Diff 2.x has return types added to FieldDiffBuilderBase::build.
This will fix 2.x support and not break 8.x-1.x support (since adding return types on child classes does not break compatibility).
Issue fork smart_date-3463447
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 #3
acbramley commentedComment #4
mandclu commentedThanks for this! Any chances you could provide steps to reproduce?
Comment #5
acbramley commented@mandclu I've never used this module but I maintain the Diff module. I had similar issue with another module so I've created issues for all modules extending this class.
You'd just need to install Diff 2.x and diff something using this module's field type.
Comment #6
frankied3I can confirm the above. With the Smart Date and Diff modules enabled:
Comment #7
micahw156I can confirm with above. I had to do the same fixes on one of our custom modules earlier today.
Comment #8
pearls commented+1 for RTBC.
Thanks @acbramley.
However, the same problems occur in Address, Dynamic Entity Reference, Office Hours modules. #3480456-Fatal error occurs
Maybe other modules that I don't know about also have this problem.
Wouldn't it be better to approach the issue through the Diff module?
Because it may be necessary to integrate a separate solution for each different module.
Comment #10
mandclu commentedDeclaring return types is a best practice, and may soon be officially declared as a requirement in core. Thanks @acbramley for identifying this and posting a fix. Merged in.
Comment #11
micahw156Hi,
This patch was applied to the 4.1.x branch, but it's not included in the 4.2.0 release. Fortunately, the patch still applies fine for me against that release.
I've reopened the issue so this can get fixed in the current branch.
Comment #13
mandclu commentedThanks for catching that @micahw156. This has now also been applied to the 4.2.x branch, and I will roll a new release shortly.
Comment #14
micahw156Thank you, @mandclu!