Fix issue with type of argument passed, simplify some code

main
Lucien Cartier-Tilet 8 months ago
parent c1ee222337
commit 02d8717f18
Signed by: phundrak
GPG Key ID: BD7789E705CB8DCA
  1. 6
      conlanging.el

@ -268,9 +268,9 @@ second is the Runic equivalent.")
(defun conlanging--translate (text table)
"Translate TEXT through its correspondance TABLE."
(dolist (elem table)
(setq text (replace-regexp-in-string (car elem) (cdr elem) text)))
text)
(let ((rune-table (cdr (assoc table conlanging-language-list))))
(dolist (elem rune-table text)
(setq text (replace-regexp-in-string (car elem) (cdr elem) text)))))
(defun conlanging--replace-region-by-translation (table)
"Replace region with its translation through TABLE.

Loading…
Cancel
Save