Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Adds a `hybrid_comment_template_hierarchy` filter hook. Kind of break…

…ing my own rule of not adding enhancements between major version releases, but I need this filter.
  • Loading branch information...
commit 2929256f762879c112fe873d19dd397eeee377fa 1 parent 7282237
@justintadlock authored
Showing with 3 additions and 0 deletions.
  1. +3 −0  functions/comments.php
View
3  functions/comments.php
@@ -84,6 +84,9 @@ function hybrid_comments_callback( $comment, $args, $depth ) {
/* Add the fallback 'comment.php' template. */
$templates[] = 'comment.php';
+ /* Allow devs to filter the template hierarchy. */
+ $templates = apply_filters( 'hybrid_comment_template_hierarchy', $templates, $comment_type );
+
/* Locate the comment template. */
$template = locate_template( $templates );
Please sign in to comment.
Something went wrong with that request. Please try again.