fixed bug with file extensions in uri (fixed #20)