When I use '/' for the path instead of /files things work, but the path that is generated for the files contain an extra /. Here's a log snippet that shows the issue.
In these situations I've found that using a url join library often is the cleanest way to eliminate duplications and ensure urls are built properly. Failing that doing a regex replace so that /+ is replaced with / works fairly well as well.
When I use '/' for the path instead of
/files
things work, but the path that is generated for the files contain an extra/
. Here's a log snippet that shows the issue.In these situations I've found that using a url join library often is the cleanest way to eliminate duplications and ensure urls are built properly. Failing that doing a regex replace so that
/+
is replaced with/
works fairly well as well.