Opened 7 years ago
Closed 6 years ago
#43463 closed defect (bug) (duplicate)
defect: blind access of possibly negative of $pages in get_the_content
Reported by: | ComputerGuru | Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 5.1 |
Component: | Posts, Post Types | Keywords: | has-patch |
Focuses: | template | Cc: |
Description
Attached patch addresses PHP notices caused when JetPack OG is installed on a theme with header.php calling get_header()
as the first action before $page
is defined.
Stack trace of notice:
get_header() wp-content/themes/knowhow/page.php:1 locate_template() wp-includes/general-template.php:41 load_template('~/wp-content/themes/knowhow/header.php') wp-includes/template.php:647 wp_head() wp-content/themes/knowhow/header.php:14 do_action('wp_head') wp-includes/general-template.php:2614 jetpack_og_tags() wp-includes/class-wp-hook.php:286 apply_filters('jetpack_open_graph_tags') wp-content/plugins/jetpack/functions.opengraph.php:216 enhanced_og_image() wp-includes/class-wp-hook.php:288 Jetpack_Media_Summary::get() wp-content/plugins/jetpack/modules/publicize/enhanced-open-graph.php:23 Jetpack_Media_Summary::get_excerpt() wp-content/plugins/jetpack/_inc/lib/class.media-summary.php:57 apply_filters('get_the_excerpt') wp-content/plugins/jetpack/_inc/lib/class.media-summary.php:314 wp_trim_excerpt() wp-includes/class-wp-hook.php:286 get_the_content() wp-includes/formatting.php:3308
Attachments (1)
Change History (4)
Note: See
TracTickets for help on using
tickets.
Probably should be closed in favor of #41933