fix: sentry minor fix (#24588)

This commit is contained in:
Shariq Ansari 2024-01-29 18:08:11 +05:30 committed by GitHub
parent c9f8daf82d
commit 1cce6588ee
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -44,9 +44,13 @@ frappe.ui.form.on("Event", {
const [ends_on_date] = frm.doc.ends_on
? frm.doc.ends_on.split(" ")
: frm.doc.starts_on.split(" ");
: frm.doc.starts_on?.split(" ") || [];
if (frm.doc.google_meet_link && frappe.datetime.now_date() <= ends_on_date) {
if (
ends_on_date &&
frm.doc.google_meet_link &&
frappe.datetime.now_date() <= ends_on_date
) {
frm.dashboard.set_headline(
__("Join video conference with {0}", [
`<a target='_blank' href='${frm.doc.google_meet_link}'>Google Meet</a>`,