Hooks: Standardize naming of dynamic hooks to use interpolation vs concatenation.

Benefits gained in discoverability and self-documentation throughout core trump the negligible performance hit in using interpolation in hook names.

Props ramiy.
See #37748.

Built from https://develop.svn.wordpress.org/trunk@38307


git-svn-id: http://core.svn.wordpress.org/trunk@38248 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Drew Jaynes
2016-08-22 18:25:31 +00:00
parent 02939c03e5
commit 22adda2aa0
22 changed files with 64 additions and 64 deletions

View File

@@ -1413,7 +1413,7 @@ class WP_Rewrite {
*
* @param array $rules The rewrite rules generated for the current permastruct.
*/
$rules = apply_filters( $permastructname . '_rewrite_rules', $rules );
$rules = apply_filters( "{$permastructname}_rewrite_rules", $rules );
if ( 'post_tag' == $permastructname ) {
/**