Skip to content

Commit b20ec7b

Browse files
committed
Add init method to Render class
1 parent a0e9b7d commit b20ec7b

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

includes/class-micropub.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public function plugin_init() {
7777
Discovery::init();
7878

7979
// Initialize Micropub Render.
80-
\add_filter( 'the_content', array( Render::class, 'render_content' ), 1 );
80+
Render::init();
8181
}
8282

8383
/**

includes/class-render.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,13 @@
1313
* Dynamically renders Microformats2 structures as HTML.
1414
*/
1515
class Render {
16+
/**
17+
* Initialize the Render class.
18+
*/
19+
public static function init() {
20+
\add_filter( 'the_content', array( self::class, 'render_content' ), 1 );
21+
}
22+
1623
/**
1724
* Dynamically Renders Microformats 2.
1825
*

0 commit comments

Comments
 (0)