Skip to content

Commit

Permalink
use delete_if over select with assignment
Browse files Browse the repository at this point in the history
  • Loading branch information
Lee Jarvis committed May 30, 2011
1 parent 5c81bff commit 729fb27
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/chronic/chronic.rb
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def parse(text, specified_options = {})
end

# strip any non-tagged tokens
@tokens = @tokens.select { |token| token.tagged? }
@tokens.delete_if { |token| !token.tagged? }

if Chronic.debug
puts "+---------------------------------------------------"
Expand Down

0 comments on commit 729fb27

Please sign in to comment.