Changeset 9937
- Timestamp:
- 05/28/2020 05:45:32 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/cli/class-import.php
r9934 r9937 636 636 // Note that this only works with literal strings for the block name and title, and assumes that order. 637 637 $contents = file_get_contents( $filename ); 638 if ( $contents && preg_match_all( "#registerBlockType \s*[(]\s*'([-\w]+/[-\w]+)'\s*,\s*[{]\s*title\s*:[\s_(]*'([^']*)'#ms", $contents, $matches, PREG_SET_ORDER ) ) {638 if ( $contents && preg_match_all( "#registerBlockType[^{}]{0,500}[(]\s*[\"']([-\w]+/[-\w]+)[\"']\s*,\s*[{]\s*title\s*:[\s\w(]*[\"']([^\"']*)[\"']#ms", $contents, $matches, PREG_SET_ORDER ) ) { 639 639 foreach ( $matches as $match ) { 640 640 $blocks[] = (object) [
Note: See TracChangeset
for help on using the changeset viewer.