Skip to content

Commit

Permalink
Fix the regexp for judging whether a list name is required or not.
Browse files Browse the repository at this point in the history
* twittering-mode.el
(twittering-read-timeline-spec-with-completion): fix the regexp
for judging whether a list name is required or not.
  • Loading branch information
cvmat committed Feb 7, 2010
1 parent 6ea8da4 commit 07f3e20
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 11 deletions.
4 changes: 4 additions & 0 deletions ChangeLog
Expand Up @@ -11,6 +11,10 @@
* twittering-mode.el (twittering-extract-timeline-spec): add error
messages for some conditions.

* twittering-mode.el
(twittering-read-timeline-spec-with-completion): fix the regexp
for judging whether a list name is required or not.

2010-02-07 Satoshi Yatagawa <yata_github@y.hauN.org>

* twittering-mode.el (twittering-http-get): Add an optional
Expand Down
24 changes: 13 additions & 11 deletions twittering-mode.el
Expand Up @@ -2839,17 +2839,19 @@ variable `twittering-status-format'."
(spec-string (twittering-completing-read prompt dummy-hist
nil nil initial 'dummy-hist))
(spec-string
(if (string-match "^\\([^/]+\\)/$" spec-string)
(let* ((username (match-string 1 spec-string))
(list-index (twittering-get-list-index-sync username))
(listname
(if list-index
(twittering-read-list-name username list-index)
nil)))
(if listname
(concat username "/" listname)
nil))
spec-string))
(cond
((string-match "^\\([a-zA-Z0-9_-]+\\)/$" spec-string)
(let* ((username (match-string 1 spec-string))
(list-index (twittering-get-list-index-sync username))
(listname
(if list-index
(twittering-read-list-name username list-index)
nil)))
(if listname
(concat username "/" listname)
nil)))
(t
spec-string)))
(spec (twittering-string-to-timeline-spec spec-string)))
(cond
(spec (if as-string
Expand Down

0 comments on commit 07f3e20

Please sign in to comment.