fix short version

Signed-off-by: Andrey Shovkoplyas <motor4ik@gmail.com>
This commit is contained in:
Andrey Shovkoplyas 2020-03-26 11:40:00 +01:00
parent a7c2ecda42
commit 5a955cd4d2
No known key found for this signature in database
GPG Key ID: EAAB7C8622D860A4
1 changed files with 1 additions and 1 deletions

View File

@ -66,7 +66,7 @@
(defn valid-language [lang]
(if (contains? prod-translations lang)
lang
(let [short-lang (keyword (subs (name lang) 0 2))]
(let [short-lang (keyword (first (string/split (name lang) #"_")))]
(when (contains? prod-translations short-lang)
short-lang))))