Regression: baseUri for LocalDriver is invalid for fallback storage
The baseUri in the LocalDriver contains a leading slash, when the absoluteBasePath equals PATH_site.
This is the case for the 0-storage (the fallback storage for non FAL file paths).
If the baseUri contains a leading slash the public URLs will contain two slashes at the beginning which browsers interpret as a schema-less URL and try to lookup the first part of the file path as hostname.
[BUGFIX] PublicURL calculation for storage 0 is wrong
Since the refactoring of the publicURL Feature and the possibility to
link to files via jump-scripts the generation of publicUrls for files
in storage zero is broken due to the fact that every relative base-path
for this URL is appended with a slash.
If the base-path has been empty (like for storage 0), appending a slash
makes it absolute.
This patch changes the behaviour to only append a slash on non-empty
Reviewed-by: Alexander Stehlik
Tested-by: Alexander Stehlik
Reviewed-by: Xavier Perseguers
Tested-by: Xavier Perseguers