Skip to content
This repository has been archived by the owner on Dec 27, 2022. It is now read-only.

Commit

Permalink
Merge pull request #100 from xwp/bugfix/remove-quick-edit
Browse files Browse the repository at this point in the history
Disable quick edit
  • Loading branch information
westonruter authored Oct 28, 2016
2 parents 8a253fd + 8f4758c commit 629033d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions php/class-post-type.php
Original file line number Diff line number Diff line change
Expand Up @@ -285,8 +285,6 @@ public function filter_post_row_actions( $actions, $post ) {
$actions
);
} else {
unset( $actions['inline hide-if-no-js'] );

if ( isset( $actions['edit'] ) ) {
$actions['edit'] = sprintf(
'<a href="%s" aria-label="%s">%s</a>',
Expand All @@ -297,6 +295,9 @@ public function filter_post_row_actions( $actions, $post ) {
);
}
}

unset( $actions['inline hide-if-no-js'] );

return $actions;
}

Expand Down
2 changes: 1 addition & 1 deletion tests/php/test-class-post-type.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ public function test_filter_post_row_actions() {

wp_set_current_user( $admin_user_id );
$filtered_actions = apply_filters( 'post_row_actions', $original_actions, get_post( $post_id ) );
$this->assertArrayHasKey( 'inline hide-if-no-js', $filtered_actions );
$this->assertArrayNotHasKey( 'inline hide-if-no-js', $filtered_actions );
$this->assertArrayHasKey( 'customize', $filtered_actions );
$this->assertArrayHasKey( 'front-view', $filtered_actions );

Expand Down

0 comments on commit 629033d

Please sign in to comment.