This commit is contained in:
2020-06-11 17:23:41 +03:00
parent 5f8f401e90
commit 050edd1abe
3 changed files with 4 additions and 2 deletions

View File

@@ -78,6 +78,8 @@ defmodule Localizator.Translator do
|> translate_html_element(to, from, translator)
|> Meeseeks.parse(:tuple_tree)
|> Meeseeks.html()
|> String.trim_leading("<html><head></head><body>")
|> String.trim_trailing("</body></html>")
end
# Plain Text Content

View File

@@ -40,7 +40,7 @@ defmodule Localizator.Translitor do
def convert(source, locale) do
translitor =
translitors()
|> Map.get(locale)
|> Map.get("#{locale}")
translitor.convert(source)
end