We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 92c0705 commit 403c6a8Copy full SHA for 403c6a8
src/set-slack-status/default.sh
@@ -19,7 +19,7 @@ if [[ ! -z "$KMPARAM_Status_text" || $both_empty -eq 0 ]]; then
19
fi
20
21
# Calculate expiration unixtime (if set to more than 0)
22
-if [[ $(bc -l <<< "$KMPARAM_Clear_after_x_hours > 0") -eq 1 ]]; then
+if [[ ! -z "$KMPARAM_Clear_after_x_hours" && $(bc -l <<< "$KMPARAM_Clear_after_x_hours > 0") -eq 1 ]]; then
23
unix_now=$(date +%s)
24
offset=$(bc -l <<< "$KMPARAM_Clear_after_x_hours * 3600")
25
integer_offset=$(printf "%.0f" $offset)
0 commit comments