method

verify_regexp_requirements

Importance_0
v6.1.7.7 - Show latest stable - 0 notes - Class: ActionDispatch::Routing::Mapper::Mapping
verify_regexp_requirements(requirements) public

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File actionpack/lib/action_dispatch/routing/mapper.rb, line 283
          def verify_regexp_requirements(requirements)
            requirements.each do |requirement|
              if ANCHOR_CHARACTERS_REGEX.match?(requirement.source)
                raise ArgumentError, "Regexp anchor characters are not allowed in routing requirements: #{requirement.inspect}"
              end

              if requirement.multiline?
                raise ArgumentError, "Regexp multiline option is not allowed in routing requirements: #{requirement.inspect}"
              end
            end
          end
Register or log in to add new notes.