summaryrefslogtreecommitdiff
path: root/lisp/ledger-complete.el
diff options
context:
space:
mode:
Diffstat (limited to 'lisp/ledger-complete.el')
-rw-r--r--lisp/ledger-complete.el4
1 files changed, 1 insertions, 3 deletions
diff --git a/lisp/ledger-complete.el b/lisp/ledger-complete.el
index bc4b1854..fd79656a 100644
--- a/lisp/ledger-complete.el
+++ b/lisp/ledger-complete.el
@@ -157,9 +157,7 @@
(ledger-accounts)))))
(defun ledger-trim-trailing-whitespace (str)
- (let ((s str))
- (when (string-match "[ \t]*$" s)
- (replace-match "" nil nil s))))
+ (replace-regexp-in-string "[ \t]*$" "" str))
(defun ledger-fully-complete-xact ()
"Completes a transaction if there is another matching payee in the buffer.