class Prelaunch::TokenConstraint

Public Instance Methods

matches?(request) click to toggle source
# File lib/prelaunch/constraints.rb, line 9
def matches? request
  path  = Prelaunch::strip_slashes(Prelaunch.verify_path)
  match = request.fullpath.match(/^#{path}\/([A-Za-z0-9]*)([\/\?])?/)

  return false if match.nil?

  Prelaunch::valid? match[1]
end