lib/ramaze/current/request.rb in manveru-ramaze-2008.09 vs lib/ramaze/current/request.rb in manveru-ramaze-2008.10
- old
+ new
@@ -57,13 +57,11 @@
rescue ArgumentError => ex
raise ArgumentError, ex unless ex.message == 'invalid address'
end
def [](key, *rest)
- value = params[key.to_s]
- return value if rest.empty?
- keys = rest.flatten.map{|k| k.to_s}
- Array[value, *params.values_at(*keys)]
+ return params[key.to_s] if rest.empty?
+ [key, *rest].map{|k| params[k.to_s] }
end
def to_ivs(*args)
instance = Action.current.instance
args.each do |arg|