Clarify nonce verification ignores
This commit is contained in:
parent
dd629741f5
commit
7f100ac88a
|
@ -126,6 +126,7 @@ class SourceAttributionController implements RegisterHooksInterface {
|
|||
add_action(
|
||||
'woocommerce_order_save_attribution_source_data',
|
||||
function( $order, $data = array() ) {
|
||||
// Nonce check is handled by WooCommerce before woocommerce_checkout_order_created hook.
|
||||
// phpcs:ignore WordPress.Security.NonceVerification
|
||||
$source_data = $this->get_source_values( empty( $data ) ? $_POST : $data );
|
||||
$this->send_order_tracks( $source_data, $order );
|
||||
|
@ -341,6 +342,7 @@ class SourceAttributionController implements RegisterHooksInterface {
|
|||
* @return void
|
||||
*/
|
||||
private function set_customer_source_data( WC_Customer $customer ) {
|
||||
// Nonce check is handled before user_register hook.
|
||||
// phpcs:ignore WordPress.Security.NonceVerification
|
||||
foreach ( $this->get_source_values( $_POST ) as $key => $value ) {
|
||||
$customer->add_meta_data( $this->get_meta_prefixed_field( $key ), $value );
|
||||
|
|
Loading…
Reference in New Issue