From: Seamus Lee Date: Thu, 16 Jul 2020 23:22:42 +0000 (+1000) Subject: [REF] Fix a couple of jQuery errors that have cropped up X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=76859ea7ed26a85972dc387cde29d173d9e024c0;p=civicrm-core.git [REF] Fix a couple of jQuery errors that have cropped up --- 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;