summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Calviño Sánchez <danxuliu@gmail.com>2017-08-04 14:27:37 +0200
committerDaniel Calviño Sánchez <danxuliu@gmail.com>2017-08-10 12:37:57 +0200
commit5999b212d1110a56f2c1f99820a9053d184b9a0c (patch)
tree465b9277ef2ac99b0412832dff311a2332c49d38
parentdb52e861dd438a78ff492d7ca04209e83d5d8c89 (diff)
downloadnextcloud-server-5999b212d1110a56f2c1f99820a9053d184b9a0c.tar.gz
nextcloud-server-5999b212d1110a56f2c1f99820a9053d184b9a0c.zip
Refactor reloadStylesheets to receive absolute URLs
This is a preparatory step for a following change in which reloadStylesheets will have to be able to receive absolute URLs. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
-rw-r--r--apps/theming/js/settings-admin.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/theming/js/settings-admin.js b/apps/theming/js/settings-admin.js
index 8c2ab2bc08e..9d8e706e124 100644
--- a/apps/theming/js/settings-admin.js
+++ b/apps/theming/js/settings-admin.js
@@ -43,7 +43,7 @@ function preview(setting, value) {
var stylesheetsLoaded = 2;
var reloadStylesheets = function(cssFile) {
var queryString = '?reload=' + new Date().getTime();
- var url = OC.generateUrl(cssFile) + queryString;
+ var url = cssFile + queryString;
var old = $('link[href*="' + cssFile.replace("/","\/") + '"]');
var stylesheet = $("<link/>", {
rel: "stylesheet",
@@ -62,8 +62,8 @@ function preview(setting, value) {
stylesheet.appendTo("head");
};
- reloadStylesheets('/css/core/server.css');
- reloadStylesheets('/apps/theming/styles');
+ reloadStylesheets(OC.generateUrl('/css/core/server.css'));
+ reloadStylesheets(OC.generateUrl('/apps/theming/styles'));
// Preview images
var timestamp = new Date().getTime();