Merge pull request #14645 from aelia-co/Fix-Restore_Checkout_User_Filter

Restored filter during checkout validation
This commit is contained in:
Mike Jolley 2017-04-24 15:22:11 +01:00 committed by GitHub
commit ac74f17d7f
1 changed files with 1 additions and 1 deletions

View File

@ -819,7 +819,7 @@ class WC_Checkout {
* @throws Exception
*/
protected function process_customer( $data ) {
$customer_id = get_current_user_id();
$customer_id = apply_filters( 'woocommerce_checkout_customer_id', get_current_user_id() );
if ( ! is_user_logged_in() && ( $this->is_registration_required() || ! empty( $data['createaccount'] ) ) ) {
$username = ! empty( $data['account_username'] ) ? $data['account_username'] : '';