Make WordPress Core

Changes between Version 2 and Version 5 of Ticket #41394


Ignore:
Timestamp:
07/21/2017 09:27:16 PM (5 years ago)
Author:
westonruter
Comment:

I'm expanding the scope here to also account for widget_text filters applying when plugins will expect $instance['filter'] to be a boolean, not a boolean with a possible string value of content.

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #41394

    • Property Summary changed from Custom HTML widget applies widget_text filters with unexpected $instance data to Application of widget_text filters passed unexpected $instance data
  • Ticket #41394 – Description

    v2 v5  
    2121
    2222So in order to preserve backwards compatibility for plugins that look at the `$instance` param, the instance data needs to be transformed from the Custom HTML instance schema over to the Text widget instance schema.
     23
     24This is also actually the case for existing `widget_text` filters for the Text widget itself. In 4.8 the `filter` param was set to a fixed `content` but if any filters do any checking of `$instance['filter'] === true` then these checks will fail. Now that there is a boolean `legacy` instance property, we can eliminate the `content` value for the `filter` property and just always set it to `true`.