Merged in feature/MAW-855-import-code-into-aws (pull request #2)

code import from pantheon

* code import from pantheon
This commit is contained in:
Tony Volpe
2023-12-04 23:08:14 +00:00
parent 8c9b1312bc
commit 8f4b5efda6
4766 changed files with 185592 additions and 239967 deletions

View File

@@ -91,9 +91,12 @@ class WPSEO_Premium_Keyword_Export_Manager implements WPSEO_WordPress_Integratio
* @return bool True if this is a valid CSV export request.
*/
protected function is_valid_csv_export_request() {
return filter_input( INPUT_GET, 'page' ) === 'wpseo_tools'
&& filter_input( INPUT_GET, 'tool' ) === 'import-export'
&& filter_input( INPUT_POST, 'export-posts' );
// phpcs:disable WordPress.Security.NonceVerification -- Reason: Nonce is checked in export.
// phpcs:disable WordPress.Security.ValidatedSanitizedInput.InputNotSanitized -- Reason: We are strictly comparing only or ignoring the value.
return ( isset( $_GET['page'] ) && is_string( $_GET['page'] ) && wp_unslash( $_GET['page'] ) === 'wpseo_tools' )
&& ( isset( $_GET['tool'] ) && is_string( $_GET['tool'] ) && wp_unslash( $_GET['tool'] ) === 'import-export' )
&& ( isset( $_POST['export-posts'] ) && ! empty( $_POST['export-posts'] ) );
// phpcs:enable
}
/**