[meld] Fix some translation typing



commit 913f1d06d37416c78c91d09c7384505e25314a4b
Author: Kai Willadsen <kai willadsen gmail com>
Date:   Fri Dec 14 09:37:04 2018 +1000

    Fix some translation typing

 bin/meld     | 3 ++-
 meld/conf.py | 2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/bin/meld b/bin/meld
index 32694755..b6a58bf4 100755
--- a/bin/meld
+++ b/bin/meld
@@ -101,7 +101,8 @@ except locale.Error as e:
     print("Couldn't set the locale: %s; falling back to 'C' locale" % e)
     locale.setlocale(locale.LC_ALL, 'C')
 gettext.textdomain(locale_domain)
-trans = gettext.translation(locale_domain, localedir=locale_dir, fallback=True)
+trans = gettext.translation(
+    locale_domain, localedir=str(locale_dir), fallback=True)
 _ = meld.conf._ = trans.gettext
 meld.conf.ngettext = trans.ngettext
 
diff --git a/meld/conf.py b/meld/conf.py
index efbd4ac3..5bf6cd4d 100644
--- a/meld/conf.py
+++ b/meld/conf.py
@@ -20,7 +20,7 @@ PYTHON_REQUIREMENT_TUPLE = (3, 4)
 
 
 # Installed from main script
-def no_translation(gettext_string, *args):
+def no_translation(gettext_string: str) -> str:
     return gettext_string
 
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]