aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'pomu/util/str.py')
-rw-r--r--pomu/util/str.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/pomu/util/str.py b/pomu/util/str.py
index 4fcd4ac..419425b 100644
--- a/pomu/util/str.py
+++ b/pomu/util/str.py
@@ -1,2 +1,5 @@
-def pivot(string, idx):
- return (string[:idx], string[idx:])
+def pivot(string, idx, keep_pivot=True):
+ if keep_pivot:
+ return (string[:idx], string[idx:])
+ else:
+ return (string[:idx], string[idx+1:])