redding/sanford-protocol — pull request #10 by jcredding (2012-11-29 20:35:10+00:00)
Title: Modify requests to raise an exception when they are invalid

This is to setup stringifying the hash keys for request params. The problem is
if we don't verify that it's a hash before trying to stringify the keys, it will
raise errors. I think the better solution for moving forward is to raise a
`BadRequestError`, which effectively would ensure params are a `Hash` before
moving forward.

@kellyredding - When I was working on stringifying request params, I found that I couldn't reliably to that operation, because we "allowed" creating invalid `Request` objects. This changes that to no longer allow creating those. I believe the original implementation was to allow flexibility.