Merge pull request #14037 from woocommerce/fix/legacy-sync

Only call sync if callable
This commit is contained in:
Claudio Sanches 2017-04-06 10:54:58 -03:00 committed by GitHub
commit 966fd0e411
1 changed files with 5 additions and 3 deletions

View File

@ -535,10 +535,12 @@ abstract class WC_Abstract_Legacy_Product extends WC_Data {
}
// Sync prices with children
self::sync( $product_id );
if ( is_callable( array( __CLASS__, 'sync' ) ) ) {
self::sync( $product_id );
// Re-load prices
$this->read_product_data();
// Re-load prices
$this->read_product_data();
}
}
/**