aboutsummaryrefslogtreecommitdiffhomepage
path: root/examples/data/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'examples/data/plugins')
-rw-r--r--examples/data/plugins/keycmd.py5
1 files changed, 1 insertions, 4 deletions
diff --git a/examples/data/plugins/keycmd.py b/examples/data/plugins/keycmd.py
index 503b539..2fb2283 100644
--- a/examples/data/plugins/keycmd.py
+++ b/examples/data/plugins/keycmd.py
@@ -426,10 +426,7 @@ def keycmd_backspace(uzbl, *args):
'''Removes the character at the cursor position in the keycmd.'''
k = uzbl.keylet
- if not k.keycmd:
- return
-
- if k.cursor == 0:
+ if not k.keycmd or not k.cursor:
return
k.keycmd = k.keycmd[:k.cursor-1] + k.keycmd[k.cursor:]