From f1b2884943ab6fd1e3ba37b017d41b65645f49dc Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Sat, 17 Sep 2022 23:36:22 +0200 Subject: [PATCH] Don't try to send KDM email unless we have a from address. --- src/lib/kdm_with_metadata.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/lib/kdm_with_metadata.cc b/src/lib/kdm_with_metadata.cc index 5c1ab0aa6..bebb5df86 100644 --- a/src/lib/kdm_with_metadata.cc +++ b/src/lib/kdm_with_metadata.cc @@ -212,6 +212,10 @@ send_emails ( throw NetworkError (_("No mail server configured in preferences")); } + if (config->kdm_from().empty()) { + throw NetworkError(_("No KDM from address configured in preferences")); + } + for (auto const& kdms_for_cinema: kdms) { auto first = kdms_for_cinema.front(); -- 2.30.2