diff options
author | jnew-gh <github@hazelden.ca> | 2021-04-20 18:45:15 +0300 |
---|---|---|
committer | jnew-gh <github@hazelden.ca> | 2021-04-20 18:45:15 +0300 |
commit | ea7d240faa03a1a5a620a8a5aa7e7e3ab3dd3031 (patch) | |
tree | 24af253dfb25aaa3ae8c1205c9f98354924dc683 | |
parent | 4bd967ed37c90cda885a9788e7b606875f659eec (diff) |
Test whether $report_status exists
... otherwise the $where clause would start with an empty string, causing an SQL error.
-rw-r--r-- | dmarcts-report-viewer-report-list.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dmarcts-report-viewer-report-list.php b/dmarcts-report-viewer-report-list.php index 5ce7cbc..50f15a6 100644 --- a/dmarcts-report-viewer-report-list.php +++ b/dmarcts-report-viewer-report-list.php @@ -227,7 +227,7 @@ switch ($dmarc_select) { // Report Status // -------------------------------------------------------------------------- -if ( $report_status != "all" ) { +if ( $report_status != "all" && $report_status != "" ) { $where .= ( $where <> '' ? " AND" : " WHERE" ) . " " . $dmarc_result[$report_status]['status_sql_where']; } |