Parse URL and use path to lookup mime type

Lookups were failing when query params existed on the path, resulting
in a content-type of application/octet-stream.

Using the path instead resolves this issue.

related to #7
related to #10