Skip to content

Commit

Permalink
loader.js: Prepend the base url to all relative links
Browse files Browse the repository at this point in the history
refs #2916
  • Loading branch information
nilmerg committed Jun 6, 2019
1 parent 2377615 commit a5de6ed
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions public/js/icinga/loader.js
Expand Up @@ -72,6 +72,11 @@
autorefresh = false;
}

if (url[0] !== '/') {
// TODO: Add an exception for named anchors? Though, currently it resembles a browser's behavior
url = this.baseUrl + '/' + url;
}

this.icinga.logger.debug('Loading ', url, ' to ', $target);

// We should do better and ignore requests without target and/or id
Expand Down

0 comments on commit a5de6ed

Please sign in to comment.