Store details: check if industries exist before trimming (https://github.com/woocommerce/woocommerce-admin/pull/4120)
This commit is contained in:
parent
61f650a2a2
commit
67b417af03
|
@ -131,7 +131,11 @@ class StoreDetails extends Component {
|
|||
*
|
||||
* This comment may be removed when a refactor to wp.data datatores is complete.
|
||||
*/
|
||||
if ( region !== 'US' ) {
|
||||
if (
|
||||
region !== 'US' &&
|
||||
profileItems.industry &&
|
||||
profileItems.industry.length
|
||||
) {
|
||||
const cbdSlug = 'cbd-other-hemp-derived-products';
|
||||
const trimmedIndustries = profileItems.industry.filter(
|
||||
( industry ) => {
|
||||
|
|
Loading…
Reference in New Issue