From 76859ea7ed26a85972dc387cde29d173d9e024c0 Mon Sep 17 00:00:00 2001 From: Seamus Lee Date: Fri, 17 Jul 2020 09:22:42 +1000 Subject: [PATCH] [REF] Fix a couple of jQuery errors that have cropped up --- js/Common.js | 2 +- templates/CRM/Contact/Page/View/Summary.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/js/Common.js b/js/Common.js index 33cefb23f1..56f17f8b16 100644 --- a/js/Common.js +++ b/js/Common.js @@ -967,7 +967,7 @@ if (!CRM.vars) CRM.vars = {}; }); } }); - if ($("input:radio[name=radio_ts]").size() == 1) { + if ($("input:radio[name=radio_ts]").length == 1) { $("input:radio[name=radio_ts]").prop("checked", true); } $('.crm-select2:not(.select2-offscreen, .select2-container)', e.target).crmSelect2(); diff --git a/templates/CRM/Contact/Page/View/Summary.js b/templates/CRM/Contact/Page/View/Summary.js index a610482703..1d57d9992c 100644 --- a/templates/CRM/Contact/Page/View/Summary.js +++ b/templates/CRM/Contact/Page/View/Summary.js @@ -196,7 +196,7 @@ document.title = $('title').html().replace(oldName, contactName); oldName = contactName; } - $('#contactname-block').load(refreshTitle); + $('#contactname-block').on('load', refreshTitle); refreshTitle(); var clicking; -- 2.25.1