Fixing Download Issue (with Issue Security) for API installed in subdirectory.

Fixes a small issue when the API is not installed at the root of a subdomain and instead is installed just in a subfolder.