Add nonces for security

dry up redundencies
This commit is contained in:
2026-02-09 21:30:13 -08:00
parent 40099aa68a
commit 999c2cc866
5 changed files with 43 additions and 52 deletions
+1 -1
View File
@@ -928,7 +928,7 @@ class HSSM_Slides_CPT {
public function ajax_update_slide_order() {
// Verify nonce and permissions
if ( ! wp_verify_nonce( $_POST['nonce'], 'hssm_update_slide_order' ) || ! current_user_can( 'edit_posts' ) ) {
wp_die( 'Unauthorized' );
wp_send_json_error( 'Unauthorized' );
}
if ( isset( $_POST['slide_ids'] ) && is_array( $_POST['slide_ids'] ) ) {