From b29d8e106e5cd394156d0cfa28dcf953178be462 Mon Sep 17 00:00:00 2001 From: Joe Dolson Date: Tue, 7 Jan 2025 17:51:50 -0600 Subject: [PATCH] Update my-calendar-settings.php --- src/my-calendar-settings.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/my-calendar-settings.php b/src/my-calendar-settings.php index b2e4e4ba..7de3f7f0 100644 --- a/src/my-calendar-settings.php +++ b/src/my-calendar-settings.php @@ -525,8 +525,8 @@ function mc_import_settings() { if ( isset( $_FILES['mc-import-settings'] ) ) { $nonce = wp_verify_nonce( $_POST['_wpnonce'], 'my-calendar-nonce' ); if ( $nonce ) { - $size = isset( $_FILES['mc-import-settings']['size'] ) ? absint( $_FILES['mc-import-settings']['size'] ) : 0; - $name = isset( $_FILES['mc-import-settings']['tmp_name'] ) ? sanitize_text_field( $_FILES['mc-import-settings']['tmp_name'] ) : ''; + $size = isset( $_FILES['mc-import-settings']['size'] ) ? absint( $_FILES['mc-import-settings']['size'] ) : 0; + $name = isset( $_FILES['mc-import-settings']['tmp_name'] ) ? sanitize_text_field( $_FILES['mc-import-settings']['tmp_name'] ) : ''; global $wp_filesystem; require_once ABSPATH . '/wp-admin/includes/file.php'; WP_Filesystem();