Skip to content

Commit

Permalink
Update data migration (inventree#7455)
Browse files Browse the repository at this point in the history
- Handle case with missing data
  • Loading branch information
SchrodingersGat authored Jun 16, 2024
1 parent 946390a commit db7632e
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ def convert_legacy_labels(table_name, model_name, template_model):
}

for field in non_null_fields:
if data[field] is None:
if data.get(field, None) is None:
data[field] = ''

# Skip any "builtin" labels
Expand Down

0 comments on commit db7632e

Please sign in to comment.