summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKyle Meyer <kyle@kyleam.com>2014-06-05 01:06:16 -0400
committerKyle Meyer <kyle@kyleam.com>2014-06-05 01:06:16 -0400
commit874bb06cd67a92fdf0f420221d6954e72e614bb5 (patch)
tree490002f44ddf22d973acee230ca294052cf1d1f9
parentcfbe94f82aeabaa3b7258e253ea801a567d5912a (diff)
downloadbog-874bb06cd67a92fdf0f420221d6954e72e614bb5.tar.gz
Simplify bog-citekey-p
-rw-r--r--bog.el4
1 files changed, 1 insertions, 3 deletions
diff --git a/bog.el b/bog.el
index e5f1493..9577161 100644
--- a/bog.el
+++ b/bog.el
@@ -263,9 +263,7 @@ year, and the first meaningful word in the title)."
prop)))
(defun bog-citekey-p (text)
- "Indicate if all of TEXT matches `bog-citekey-format'."
- (string-match bog-citekey-format text)
- (when (equal (length text) (match-end 0))
+ (when (string-match-p (format "^%s$" bog-citekey-format) text)
t))
(defun bog-all-citekeys ()