fix: set link field to undefined instead of empty string
This breaks other code where undefined values are removed, technically invalid value for link field => unset link field so it should be undefined
This commit is contained in:
parent
5ee5573d21
commit
b633f31bf4
1 changed files with 1 additions and 1 deletions
|
|
@ -471,7 +471,7 @@ frappe.ui.form.ControlLink = class ControlLink extends frappe.ui.form.ControlDat
|
|||
docname: value,
|
||||
fields: columns_to_fetch,
|
||||
}).then((response) => {
|
||||
if (!response || !response.name) return "";
|
||||
if (!response || !response.name) return undefined;
|
||||
if (!docname || !columns_to_fetch.length) return response.name;
|
||||
|
||||
for (const [target_field, source_field] of Object.entries(fetch_map)) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue