Skip to content

Commit

Permalink
Disabled skipping of undocumented hooks.
Browse files Browse the repository at this point in the history
  • Loading branch information
Rarst committed Dec 17, 2014
1 parent cb5fda9 commit 45ff10e
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions lib/class-importer.php
Expand Up @@ -368,13 +368,20 @@ public function import_function( array $data, $parent_post_id = 0, $import_inter
* @return bool|int Post ID of this hook, false if any failure. * @return bool|int Post ID of this hook, false if any failure.
*/ */
public function import_hook( array $data, $parent_post_id = 0, $import_internal = false ) { public function import_hook( array $data, $parent_post_id = 0, $import_internal = false ) {

/* TODO core-centric assumption, shouldn't be handled on import step
if ( 0 === strpos( $data['doc']['description'], 'This action is documented in' ) ) { if ( 0 === strpos( $data['doc']['description'], 'This action is documented in' ) ) {
return false; return false;
} elseif ( 0 === strpos( $data['doc']['description'], 'This filter is documented in' ) ) { }
if ( 0 === strpos( $data['doc']['description'], 'This filter is documented in' ) ) {
return false; return false;
} elseif ( '' === $data['doc']['description'] && '' === $data['doc']['long_description'] ) { }
if ( '' === $data['doc']['description'] && '' === $data['doc']['long_description'] ) {
return false; return false;
} }
*/


$hook_id = $this->import_item( $data, $parent_post_id, $import_internal, array( 'post_type' => $this->post_type_hook ) ); $hook_id = $this->import_item( $data, $parent_post_id, $import_internal, array( 'post_type' => $this->post_type_hook ) );


Expand Down

0 comments on commit 45ff10e

Please sign in to comment.