Keep $QUTE_COUNT unset if a count is not given
This commit is contained in:
parent
a9725ddb4a
commit
b05738dd6c
@ -1252,9 +1252,11 @@ class CommandDispatcher:
|
||||
env = {
|
||||
'QUTE_MODE': 'command',
|
||||
'QUTE_SELECTED_TEXT': selection,
|
||||
'QUTE_COUNT': str(count), # must be a string
|
||||
}
|
||||
|
||||
if count is not None:
|
||||
env['QUTE_COUNT'] = str(count) # must be str
|
||||
|
||||
idx = self._current_index()
|
||||
if idx != -1:
|
||||
env['QUTE_TITLE'] = self._tabbed_browser.widget.page_title(idx)
|
||||
|
@ -4,7 +4,7 @@ if [ "$QUTE_COUNT" = "5" ]; then
|
||||
|
||||
echo "message-info 'Count is five!'" >> "$QUTE_FIFO"
|
||||
|
||||
elif [ "$QUTE_COUNT" = "None" ]; then
|
||||
elif [ -z "$QUTE_COUNT" ]; then
|
||||
|
||||
echo "message-info 'No count!'" >> "$QUTE_FIFO"
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user