From 608253556d5649fc3286627ca0dce6f87e5fd17e Mon Sep 17 00:00:00 2001 From: lingdocs <71590811+lingdocs@users.noreply.github.com> Date: Mon, 5 Jul 2021 21:16:46 +0300 Subject: [PATCH] safegaurd conjugation - TODO: this should go in the actual conjugation function --- package.json | 2 +- src/components/ConjugationViewer.tsx | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index bb8f564..896b367 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@lingdocs/pashto-inflector", - "version": "0.6.1", + "version": "0.6.2", "author": "lingdocs.com", "description": "A Pashto inflection and verb conjugation engine, inculding React components for displaying Pashto text, inflections, and conjugations", "homepage": "https://verbs.lingdocs.com", diff --git a/src/components/ConjugationViewer.tsx b/src/components/ConjugationViewer.tsx index 8864fd8..322f9e6 100644 --- a/src/components/ConjugationViewer.tsx +++ b/src/components/ConjugationViewer.tsx @@ -195,6 +195,7 @@ function ConjugationViewer({ entry, complement, textOptions, aayTailType }: { }); const conjugation = (() => { + if (!(entry.c && entry.c.slice(0, 2) === "v.")) return undefined; try { return conjugateVerb(entry, aayTailType ? aayTailType : "aay", complement); } catch(e) {