Make WordPress Core


Ignore:
Timestamp:
09/07/2023 08:46:53 PM (3 years ago)
Author:
hellofromTonya
Message:

Code Modernization: Use wp_trigger_error() in WP_Text_Diff_Renderer_Table magic methods.

Replaces trigger_error() with wp_trigger_error() in each of the WP_Text_Diff_Renderer_Table magic methods.

[56354] added the dynamic properties deprecation messages to the __get(), __set(), __isset(), __unset() magic methods. Since that commit, wp_trigger_error() was introduced (see [56530]) as a wrapper for trigger_error().

Follow-up to [56354], [56530].

See #58898, #57686.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-text-diff-renderer-table.php

    r56354 r56544  
    522522                }
    523523
    524                 trigger_error(
     524                wp_trigger_error(
     525                        __METHOD__,
    525526                        "The property `{$name}` is not declared. Getting a dynamic property is " .
    526527                        'deprecated since version 6.4.0! Instead, declare the property on the class.',
     
    545546                }
    546547
    547                 trigger_error(
     548                wp_trigger_error(
     549                        __METHOD__,
    548550                        "The property `{$name}` is not declared. Setting a dynamic property is " .
    549551                        'deprecated since version 6.4.0! Instead, declare the property on the class.',
     
    566568                }
    567569
    568                 trigger_error(
     570                wp_trigger_error(
     571                        __METHOD__,
    569572                        "The property `{$name}` is not declared. Checking `isset()` on a dynamic property " .
    570573                        'is deprecated since version 6.4.0! Instead, declare the property on the class.',
     
    588591                }
    589592
    590                 trigger_error(
     593                wp_trigger_error(
     594                        __METHOD__,
    591595                        "A property `{$name}` is not declared. Unsetting a dynamic property is " .
    592596                        'deprecated since version 6.4.0! Instead, declare the property on the class.',
Note: See TracChangeset for help on using the changeset viewer.