Added some error checking

Added a check to ServerPathMapper class to ensure it is running in a web
application and in a thread that has access to the HttpContext. If not,
it throws a more meaningful exception (than the NullReferenceException
that would have been thrown otherwise) that gives the user hints as to
where the problem might lie.
Tidy

Tidy up some code.