Ensure _product_version checks act the same regardless of the attributes being checked

This commit is contained in:
Mike Jolley 2015-09-14 12:12:05 +01:00
parent 14c0a3ce90
commit 2d90e1c6c6
1 changed files with 1 additions and 1 deletions

View File

@ -393,7 +393,7 @@ class WC_Product_Variable extends WC_Product {
$values = array();
// Pre 2.4 handling where 'slugs' were saved instead of the full text attribute
if ( $assigned_text_attributes === array_map( 'sanitize_title', $assigned_text_attributes ) && version_compare( get_post_meta( $this->id, '_product_version', true ), '2.4.0', '<' ) ) {
if ( version_compare( get_post_meta( $this->id, '_product_version', true ), '2.4.0', '<' ) ) {
$assigned_text_attributes = array_map( 'sanitize_title', $assigned_text_attributes );
foreach ( $text_attributes as $text_attribute ) {