diff --git a/rofi-task.sh b/rofi-task.sh index 3569570..b2928ff 100755 --- a/rofi-task.sh +++ b/rofi-task.sh @@ -93,10 +93,26 @@ display_current_task() { # {{{ rm --force -- "${TASKW_CURRENT_LIST}" ## If no task was selected (empty var) then exit - [ -z "${TITLE}" ] && echo "Cancelled." && exit 0 + if [ -z "${TITLE}" ]; then + echo "Cancelled." + debug_message "display_current_task − \ +TITLE var is ${RED}empty${COLOR_DEBUG}." + exit 0 + else + debug_message "display_current_task − \ +TITLE var: ${RED}${TITLE}${RESET}." + fi ## If no ID was found (empty var) then exit - [ -z "${ID}" ] && echo "Cancelled." && exit 0 + if [ -z "${ID}" ]; then + echo "Cancelled." + debug_message "display_current_task − \ +ID var is ${RED}empty${COLOR_DEBUG}." + exit 0 + else + debug_message "display_current_task − \ +ID var: ${RED}${ID}${RESET}." + fi ## Kill any pomodorrior process running for the current task pkill --full -- "${TITLE}"