From 9af69ca2a5ed74acefdaedad6d189bdfd9e61e0e Mon Sep 17 00:00:00 2001 From: Christoph Wurst Date: Tue, 9 Oct 2018 07:44:26 +0200 Subject: Fix usage of deprecated OC.webroot Signed-off-by: Christoph Wurst --- core/js/js.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'core/js/js.js') diff --git a/core/js/js.js b/core/js/js.js index 3f7ad233e31..e7e1c301bb5 100644 --- a/core/js/js.js +++ b/core/js/js.js @@ -99,7 +99,7 @@ var OCP = {}, * @return {string} the url */ linkToRemoteBase:function(service) { - return OC.webroot + '/remote.php/' + service; + return OC.getRootPath() + '/remote.php/' + service; }, /** @@ -119,7 +119,7 @@ var OCP = {}, */ linkToOCS: function(service, version) { version = (version !== 2) ? 1 : 2; - return window.location.protocol + '//' + window.location.host + OC.webroot + '/ocs/v' + version + '.php/' + service + '/'; + return window.location.protocol + '//' + window.location.host + OC.getRootPath() + '/ocs/v' + version + '.php/' + service + '/'; }, /** @@ -157,10 +157,10 @@ var OCP = {}, } if(oc_config.modRewriteWorking == true) { - return OC.webroot + _build(url, params); + return OC.getRootPath() + _build(url, params); } - return OC.webroot + '/index.php' + _build(url, params); + return OC.getRootPath() + '/index.php' + _build(url, params); }, /** @@ -172,7 +172,7 @@ var OCP = {}, */ filePath:function(app,type,file){ var isCore=OC.coreApps.indexOf(app)!==-1, - link=OC.webroot; + link=OC.getRootPath(); if(file.substring(file.length-3) === 'php' && !isCore){ link+='/index.php/apps/' + app; if (file != 'index.php') { -- cgit v1.2.3