Skip to content

Commit

Permalink
Update class-algolia-woo-indexer.php
Browse files Browse the repository at this point in the history
  • Loading branch information
w3bdesign committed Sep 14, 2020
1 parent 3688f53 commit a80be14
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions classes/class-algolia-woo-indexer.php
Original file line number Diff line number Diff line change
Expand Up @@ -506,7 +506,6 @@ function () {
* Check if product is in stock if $index_in_stock is set to 1
*/
if ( '1' === $index_in_stock && $product->is_in_stock() ) {

/**
* Extract image from $product->get_image()
*/
Expand All @@ -530,11 +529,9 @@ function () {
* Do not check if product is in stock if $index_in_stock is set to 0
*/
if ( '0' === $index_in_stock ) {

/**
* Extract image from $product->get_image()
*/

*/
preg_match('/<img(.*)src(.*)=(.*)"(.*)"/U', $product->get_image(), $result);
$product_image = array_pop($result);

Expand Down

0 comments on commit a80be14

Please sign in to comment.