From 65533330021efef46923c61f20de0c1bdba8cc06 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Tue, 17 Jun 2014 22:20:26 -0700 Subject: [PATCH] web: check UOTD email addr --- html/inc/uotd.inc | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/html/inc/uotd.inc b/html/inc/uotd.inc index 0ab0ec32cb..f34ebf0e14 100644 --- a/html/inc/uotd.inc +++ b/html/inc/uotd.inc @@ -81,7 +81,10 @@ function select_uotd() { // If the number of approved profiles dips below a threshold, // email the sys admin every time we pick a new one. // - if ($result && mysql_num_rows($result) < UOTD_THRESHOLD) { + if (defined('UOTD_ADMIN_EMAIL') + && $result + && mysql_num_rows($result) < UOTD_THRESHOLD + ) { $u = new BoincUser; $u->email_addr = UOTD_ADMIN_EMAIL; $u->name = "UOTD admin";