eleven-solutions-common-website-unique-web 19.0.6 → 19.0.7

Sign up to get free protection for your applications and to get access to all the features.
@@ -267,9 +267,8 @@ const TaxonomyForm = ({ url }) => {
267
267
  setTempTaxonomy([]);
268
268
  alert("Multiple taxonomies added successfully");
269
269
  const response = yield fetchTaxonomiessApi(url);
270
- const filteredTaxonomies = response.filter((taxonomy) => taxonomy.type === inputType);
271
- // setSimilarTaxonomies(filteredTaxonomies);
272
- setSimilarTaxonomies((prevTaxonomies) => prevTaxonomies.filter((taxonomy) => taxonomy.id !== id));
270
+ const filteredTaxonomies = response.filter((taxonomy) => taxonomy.type === type);
271
+ setSimilarTaxonomies(filteredTaxonomies);
273
272
  }
274
273
  catch (error) {
275
274
  console.error("Error adding multiple taxonomies:", error);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eleven-solutions-common-website-unique-web",
3
- "version": "19.0.6",
3
+ "version": "19.0.7",
4
4
  "main": "./dist/index.js",
5
5
  "scripts": {
6
6
  "build": "tsc",
@@ -351,12 +351,9 @@ const TaxonomyForm = ({ url }: TaxionomyFormProps) => {
351
351
  alert("Multiple taxonomies added successfully");
352
352
  const response = await fetchTaxonomiessApi(url);
353
353
  const filteredTaxonomies = (response as { type: string }[]).filter(
354
- (taxonomy: { type: string }) => taxonomy.type === inputType
355
- );
356
- // setSimilarTaxonomies(filteredTaxonomies);
357
- setSimilarTaxonomies((prevTaxonomies) =>
358
- prevTaxonomies.filter((taxonomy) => taxonomy.id !== id)
354
+ (taxonomy: { type: string }) => taxonomy.type === type
359
355
  );
356
+ setSimilarTaxonomies(filteredTaxonomies);
360
357
  } catch (error) {
361
358
  console.error("Error adding multiple taxonomies:", error);
362
359
  alert("Failed to add multiple taxonomies");