Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #38540, comment 2


Ignore:
Timestamp:
11/09/2016 01:36:50 AM (8 years ago)
Author:
welcher
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #38540, comment 2

    initial v1  
    11I'm writing up some tests for `\get_theme_starter_content` and noticed that it is possible to do this `add_theme_support( 'starter-content' )` which causes a PHP invalid foreach error.
    22
    3 I am not sure how common that would be but there is no check in 'get_theme_starter_content` to ensure that `$theme_support` is an array.
    4 
    5 I've attached a patch with tests to address this and introduce a new test file for the method.
     3I am not sure how common that would be but there is no check in `get_theme_starter_content` to ensure that `$theme_support` is an array. I've attached a patch with tests to address this and introduce a new test file for the method.