浏览代码

Missing finally return in "checkforUTF8"

no matter on Python 3: following "a.decode" uses its own default for the empty argument.
fails on Python 2, since "a.decode" requires a non-empty argument!
Thomas Schneider 2 年之前
父节点
当前提交
4cb5cc0916
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      metrixpp/ext/std/tools/collect.py

+ 2 - 0
metrixpp/ext/std/tools/collect.py

@@ -201,6 +201,8 @@ class DirectoryReader():
                     ):
                         return "utf_8"
                 return default
+
+            return default;
           # end of checkforUTF8 ------------------------------------------------
 
         # Subroutine readtextfile