lib/usher/node.rb in joshbuddy-usher-0.3.4 vs lib/usher/node.rb in joshbuddy-usher-0.3.5
- old
+ new
@@ -98,10 +98,14 @@
when :*
params << [next_part.value.name, []] unless params.last && params.last.first == next_part.value.name
params.last.last << part unless part.is_a?(Symbol)
find(request, path, params)
when :':'
+ var = next_part.value
params << [next_part.value.name, part]
+ until (path.first == var.look_ahead) || path.empty?
+ params.last.last << path.shift.to_s
+ end
next_part.find(request, path, params)
end
end
else
nil