diff options
Diffstat (limited to 'lib/rubygems/commands/query_command.rb')
-rw-r--r-- | lib/rubygems/commands/query_command.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/rubygems/commands/query_command.rb b/lib/rubygems/commands/query_command.rb index f25d120b88..70f8127292 100644 --- a/lib/rubygems/commands/query_command.rb +++ b/lib/rubygems/commands/query_command.rb @@ -86,7 +86,7 @@ is too hard to use. name = Array(options[:name]) else args = options[:args].to_a - name = options[:exact] ? args : args.map{|arg| /#{arg}/i } + name = options[:exact] ? args.map{|arg| /\A#{Regexp.escape(arg)}\Z/ } : args.map{|arg| /#{arg}/i } end prerelease = options[:prerelease] |