Method: ActionDispatch::Journey::Path::Pattern::UnanchoredRegexp#accept

Defined in:
actionpack/lib/action_dispatch/journey/path/pattern.rb

#accept(node) ⇒ Object



118
119
120
121
# File 'actionpack/lib/action_dispatch/journey/path/pattern.rb', line 118

def accept(node)
  path = visit node
  path == "/" ? %r{\A/} : %r{\A#{path}(?:\b|\Z|/)}
end