Skip translation refering to unknown XML ID or unactivated source
Closes #12969 (grafted from 563cb007e55c30ed03e3fb4eb74b623bfa8fd6e1) --HG-- branch : 7.0
This commit is contained in:
1 parent
414ee45199
commit
7d2d1f7c48
1 file changed
+4
-2
@@ -856,13 +856,15 @@ class Translation(ModelSQL, ModelView):
|
||||
if (model in fs_id2prop
|
||||
and res_id in fs_id2prop[model]):
|
||||
res_id, noupdate = fs_id2prop[model][res_id]
|
||||
elif res_id:
|
||||
continue
|
||||
|
||||
if res_id:
|
||||
try:
|
||||
res_id = int(res_id)
|
||||
except ValueError:
|
||||
res_id = None
|
||||
if not res_id:
|
||||
continue
|
||||
else:
|
||||
res_id = -1
|
||||
|
||||
translation.res_id = res_id
|
||||
|
||||
Reference in new issue
Block a user