[MERGE] forward port branch 8.0 up to 295f627

This commit is contained in:
Christophe Simonis
2016-09-30 15:35:57 +02:00
2 changed files with 3 additions and 2 deletions
+1 -1
View File
@@ -102,7 +102,7 @@ class CompanyLDAP(osv.osv):
_logger.warning('Could not format LDAP filter. Your filter should contain one \'%s\'.')
return False
try:
results = self.query(conf, filter)
results = self.query(conf, filter.encode('utf-8'))
# Get rid of (None, attrs) for searchResultReference replies
results = [i for i in results if i[0]]
+2 -1
View File
@@ -859,8 +859,9 @@ def trans_generate(lang, modules, cr):
def get_module_from_path(path):
for (mp, rec) in path_list:
mp = os.path.join(mp, '')
if rec and path.startswith(mp) and os.path.dirname(path) != mp:
path = path[len(mp)+1:]
path = path[len(mp):]
return path.split(os.path.sep)[0]
return 'base' # files that are not in a module are considered as being in 'base' module