Skip to content

Commit a00583a

Browse files
committed
Match shorter
before: without_list_prefix("[ruby-dev:1] Re: [ruby-list:3486] Re: eval with dynamic binding [Re: meta programming features]") #=> "" after: without_list_prefix("[ruby-dev:1] Re: [ruby-list:3486] Re: eval with dynamic binding [Re: meta programming features]") #=> "Re: [ruby-list:3486] Re: eval with dynamic binding [Re: meta programming features]"
1 parent cd5c23a commit a00583a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/helpers/messages_helper.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module MessagesHelper
22
def without_list_prefix(subject)
3-
subject.sub(/^\[.+\]\s*/, '')
3+
subject.sub(/^\[.+?\]\s*/, '')
44
end
55

66
MARGIN = 50

0 commit comments

Comments
 (0)