refactor: usage of in_list
diff --git a/erpnext/public/js/communication.js b/erpnext/public/js/communication.js
index d9187f8b..c8905e1 100644
--- a/erpnext/public/js/communication.js
+++ b/erpnext/public/js/communication.js
@@ -20,7 +20,7 @@
 			);
 		}
 
-		if (!in_list(["Lead", "Opportunity"], frm.doc.reference_doctype)) {
+		if (!["Lead", "Opportunity"].includes(frm.doc.reference_doctype)) {
 			frm.add_custom_button(
 				__("Lead"),
 				() => {