From f37d9590100efba4e541e5fcb49ef59658939c84 Mon Sep 17 00:00:00 2001 From: phl0 Date: Sat, 20 Jan 2024 23:59:45 +0100 Subject: [PATCH] Do not upload to LoTW if signing failed --- application/controllers/Lotw.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/application/controllers/Lotw.php b/application/controllers/Lotw.php index 20f4c6be6..4bb744ee2 100644 --- a/application/controllers/Lotw.php +++ b/application/controllers/Lotw.php @@ -262,6 +262,11 @@ class Lotw extends CI_Controller { // Build File to save $adif_to_save = $this->load->view('lotw_views/adif_views/adif_export', $data, TRUE); + if (strpos($adif_to_save, '')) { + // Signing failed + echo "Signing failed."; + continue; + } // create folder to store upload file if (!file_exists('./uploads/lotw')) { @@ -971,6 +976,7 @@ class Lotw extends CI_Controller { } } else { log_message('error', 'Error signing LoTW log.'); + return null; }