Skip to content

Commit 1b0111d

Browse files
committed
No row = no type (like core)
1 parent 7f2abe2 commit 1b0111d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

includes/data-stores/class-wc-product-data-store-custom-table.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -609,11 +609,11 @@ protected function clear_caches( &$product ) {
609609
*
610610
* @since 3.0.0
611611
* @param int $product_id Product ID to query.
612-
* @return string
612+
* @return string|bool
613613
*/
614614
public function get_product_type( $product_id ) {
615615
$data = $this->get_product_row_from_db( $product_id );
616-
return ! empty( $data['type'] ) ? $data['type'] : 'simple';
616+
return ! empty( $data['type'] ) ? $data['type'] : false;
617617
}
618618

619619
/**

0 commit comments

Comments
 (0)