mirror of
https://github.com/codeninjasllc/discourse.git
synced 2025-04-01 09:39:51 -04:00
correct behavior
This commit is contained in:
parent
01fcc7503a
commit
f6d56fef9e
1 changed files with 2 additions and 1 deletions
|
@ -34,7 +34,8 @@ export default function loadScript(url, opts) {
|
|||
var cdnUrl = url;
|
||||
|
||||
if (Discourse.CDN && url[0] === "/") {
|
||||
cdnUrl = Discourse.CDN + url;
|
||||
// ensure stuff is rooted correctly
|
||||
cdnUrl = Discourse.CDN.replace(/\/$/,"") + url.substr(1);
|
||||
}
|
||||
|
||||
// Some javascript depends on the path of where it is loaded (ace editor)
|
||||
|
|
Loading…
Add table
Reference in a new issue