File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -288,15 +288,15 @@ protected function update_post_from_markdown_source( $post_id ) {
288288$ yaml_parser = new Yaml ();
289289$ yaml = $ yaml_parser ->loadString ( $ yaml_matches [1 ] );
290290// Strip YAML doc from the header
291- $ markdown = substr ( $ markdown , strlen ( $ yaml_matches [0 ] ) );
291+ $ markdown = mb_substr ( $ markdown , mb_strlen ( $ yaml_matches [0 ] ) );
292292} else {
293293$ yaml = array ();
294294}
295295
296296$ title = null ;
297297if ( preg_match ( '/^\n*#\s(.+)/ ' , $ markdown , $ matches ) ) {
298298$ title = $ matches [1 ];
299- $ markdown = preg_replace ( '/^\n*#\swp\ s(.+)/ ' , '' , $ markdown );
299+ $ markdown = preg_replace ( '/^\n*#\s(.+)/ ' , '' , $ markdown );
300300}
301301// Allow YAML override.
302302if ( isset ( $ yaml ['title ' ] ) ) {
You can’t perform that action at this time.
0 commit comments