Fix double slashes in resource urls generated in template