Skip to content

Commit 5da9ed6

Browse files
author
Pedro M. Baeza
authored
Merge pull request OCA#5473 from Tecnativa/17.0-ou_fix-base-private_contact_null_name
[17.0][OU-FIX] base: Cover private contact with no name
2 parents 78e3767 + fe4cc24 commit 5da9ed6

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

openupgrade_scripts/scripts/base/17.0.1.3/pre-migration.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,8 @@ def _handle_partner_private_type(cr):
222222
openupgrade.copy_columns(cr, _column_copies)
223223
# Change contact type and erase sensitive information
224224
query = "type = 'contact'"
225+
# name of private contact may be null, which is forbidden by res_partner_check_name
226+
query += ", name = COALESCE(name, '*****')"
225227
for field in [
226228
"street",
227229
"street2",

0 commit comments

Comments
 (0)