Skip to content

Commit

Permalink
fix: no optional chaining in v13
Browse files Browse the repository at this point in the history
  • Loading branch information
RJPvT committed Apr 6, 2023
1 parent 0c7ac16 commit d08627b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frappe/public/js/frappe/form/script_manager.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ frappe.ui.form.ScriptManager = Class.extend({
let client_script;

// process the custom script for this form
if (this.frm.doctype_layout?.client_script) {
if (this.frm.doctype_layout && this.frm.doctype_layout.client_script) {
// add a newline to avoid conflict with doctype JS
client_script += `\n${this.frm.doctype_layout.client_script}`;
}
Expand Down

0 comments on commit d08627b

Please sign in to comment.