Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #51525, comment 3


Ignore:
Timestamp:
10/15/2020 08:12:04 PM (4 years ago)
Author:
jrf
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #51525, comment 3

    initial v1  
    2525Once PHP 8 becomes the minimum PHP version for WordPress (in twenty years or so), union types could be used in the hooked-in functions and a `try-catch` be added to `apply_filters()` to catch mismatches, but that's another matter.
    2626
    27 Actually, adding the `try-catch` in `apply_filters()` already with a ''doing it wrong'' would probably not be a bad idea anyway as it would prevent potential fatal errors when plugins already choose to drop PHP 5.6 support and add PHP 7 type declarations, but to be fair, that is outside the scope of this ticket and deserves it own discussion.
     27Actually, adding the `try-catch` in `apply_filters()` already with a ''doing it wrong'' would probably not be a bad idea anyway as it would prevent potential fatal errors when plugins already choose to drop PHP 5.6 support and add PHP 7 type declarations, but to be fair, that is outside the scope of this ticket and deserves its own discussion.
    2828
    2929