Defect HC-13023

searchTerm fails when all child skus of products are published but underlying skus are un-published and vice-versa

Software

Customer case Applies to Corrected in
CS0259470 V9.1.6.0 9.1.9.0

Observed behavior

The searchTerm api fails with error when product is in published state and skus are not published or vice-versa. The error will appear similar to the following: 2021-09-17T19:12:41.058Z [Default Executor-thread-6] [7008982699588251986] ERROR c.h.c.s.e.SearchExceptionHandler.handleGenericException:125 - null java.lang.ArrayIndexOutOfBoundsException: null

Expected behavior

There should be no failure in the API.

Resolution

The code was not properly considering the combination of the product and SKU's Displayable flags, leading to a under-allocated array for the results. This has been corrected.