class AuthorizationHeaderParser::ParseError
Public Class Methods
new(message, scanner)
click to toggle source
Calls superclass method
# File lib/authorization_header_parser.rb, line 10 def initialize(message, scanner) str = scanner.string from = [(scanner.pos - 5), 0].sort.pop upto = [(scanner.pos + 5), str.length].sort.shift piece = str[from..upto] super "#{message} - at #{scanner.pos} (around #{piece.inspect})" end