lib/ramaze/current/request.rb in manveru-ramaze-2008.12 vs lib/ramaze/current/request.rb in manveru-ramaze-2009.01
- old
+ new
@@ -194,12 +194,12 @@
# Valid keys are objects that respond to :to_s
#
# Example:
# request.params
# # => {'name' => 'jason', 'age' => '45', 'job' => 'lumberjack'}
- # request.sub('name')
+ # request.subset('name')
# # => {'name' => 'jason'}
- # request.sub(:name, :job)
+ # request.subset(:name, :job)
# # => {'name' => 'jason', 'job' => 'lumberjack'}
def subset(*keys)
keys = keys.map{|k| k.to_s }
params.reject{|k,v| not keys.include?(k) }