We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ad13b9e commit a43f170Copy full SHA for a43f170
plugins/wp-graphql-headless-webhooks/src/Admin/WebhooksAdmin.php
@@ -233,11 +233,9 @@ public function handle_webhook_delete() {
233
* @return void
234
*/
235
public function handle_admin_actions() {
236
- if (
237
- ( isset( $_REQUEST['action'] ) && 'delete' === $_REQUEST['action'] ) ||
238
- ( isset( $_REQUEST['action2'] ) && 'delete' === $_REQUEST['action2'] )
239
- ) {
240
- if ( ! $this->verify_admin_permission() || ! $this->verify_nonce( 'bulk-webhooks', '_wpnonce' ) ) {
+ // Handle single webhook delete
+ if ( isset( $_REQUEST['action'] ) && 'delete' === $_REQUEST['action'] && isset( $_GET['webhook'] ) ) {
+ if ( ! $this->verify_admin_permission() ) {
241
return;
242
}
243
0 commit comments