@bjsdistribution/dms-client-return 0.0.35 → 0.0.37

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8916,19 +8916,19 @@ function SelectionFilter() {
8916
8916
  });
8917
8917
  if (filteredClient) {
8918
8918
  var _filteredClient$actio, _filteredClient$retur;
8919
- var mappedActions = filteredClient == null || (_filteredClient$actio = filteredClient.actions) == null ? void 0 : _filteredClient$actio.map(function (action) {
8919
+ var mappedActions = Array.isArray(filteredClient == null ? void 0 : filteredClient.actions) ? filteredClient == null || (_filteredClient$actio = filteredClient.actions) == null ? void 0 : _filteredClient$actio.map(function (action) {
8920
8920
  return {
8921
8921
  label: action,
8922
8922
  value: action
8923
8923
  };
8924
- });
8924
+ }) : [];
8925
8925
  setActionTypeOptions(mappedActions);
8926
- var mappedLocations = filteredClient == null || (_filteredClient$retur = filteredClient.return_locations) == null ? void 0 : _filteredClient$retur.map(function (location) {
8926
+ var mappedLocations = Array.isArray(filteredClient == null ? void 0 : filteredClient.return_locations) ? filteredClient == null || (_filteredClient$retur = filteredClient.return_locations) == null ? void 0 : _filteredClient$retur.map(function (location) {
8927
8927
  return {
8928
8928
  label: location,
8929
8929
  value: location
8930
8930
  };
8931
- });
8931
+ }) : [];
8932
8932
  setLocationOptions(mappedLocations);
8933
8933
  }
8934
8934
  }
@@ -8954,18 +8954,18 @@ function SelectionFilter() {
8954
8954
  });
8955
8955
  var clientActions = (selectedClientValue == null ? void 0 : selectedClientValue.actions) || [];
8956
8956
  var clientLocations = (selectedClientValue == null ? void 0 : selectedClientValue.return_locations) || [];
8957
- setActionTypeOptions(clientActions == null ? void 0 : clientActions.map(function (action) {
8957
+ setActionTypeOptions(Array.isArray(clientActions) ? clientActions == null ? void 0 : clientActions.map(function (action) {
8958
8958
  return {
8959
8959
  label: action,
8960
8960
  value: action
8961
8961
  };
8962
- }));
8963
- setLocationOptions(clientLocations == null ? void 0 : clientLocations.map(function (action) {
8962
+ }) : []);
8963
+ setLocationOptions(Array.isArray(clientLocations) ? clientLocations == null ? void 0 : clientLocations.map(function (location) {
8964
8964
  return {
8965
- label: action,
8966
- value: action
8965
+ label: location,
8966
+ value: location
8967
8967
  };
8968
- }));
8968
+ }) : []);
8969
8969
  //client value
8970
8970
  if (storedClientId) {
8971
8971
  dispatch({
@@ -8994,7 +8994,7 @@ function SelectionFilter() {
8994
8994
  });
8995
8995
  }
8996
8996
  //location value
8997
- if (selectedLocationValue && selectedLocationValue.length > 0) {
8997
+ if (selectedLocationValue && (selectedLocationValue == null ? void 0 : selectedLocationValue.length) > 0) {
8998
8998
  dispatch({
8999
8999
  type: 'SET_LOCATION_FILTER',
9000
9000
  payload: selectedLocationValue