From 4387a5b2ed10ec04edb3f77531df8977e7048b7a Mon Sep 17 00:00:00 2001 From: Andreas <6977712+AndreasK79@users.noreply.github.com> Date: Sun, 30 Jul 2023 09:59:38 +0200 Subject: [PATCH] Fixed error when sat_mode is null --- application/controllers/Labels.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/application/controllers/Labels.php b/application/controllers/Labels.php index 977e5a6b..a6826bf3 100644 --- a/application/controllers/Labels.php +++ b/application/controllers/Labels.php @@ -216,7 +216,7 @@ class Labels extends CI_Controller { } // New begin function pretty_sat_mode($sat_mode) { - return(strlen($sat_mode) == 2 ? (strtoupper($sat_mode[0]).'/'.strtoupper($sat_mode[1])) : strtoupper($sat_mode)); + return(strlen($sat_mode ?? '') == 2 ? (strtoupper($sat_mode[0]).'/'.strtoupper($sat_mode[1])) : strtoupper($sat_mode ?? '')); } function finalizeData($pdf, $current_callsign, &$preliminaryData, $qso_per_label) {