Revert "Issue #3407511: Automated Drupal 10 compatibility fixes"
This reverts commit 1fb3318b.
Closes #3407511