summaryrefslogtreecommitdiffstats
path: root/core/js/js.js
diff options
context:
space:
mode:
authorSimon Eisenmann <simon@struktur.de>2016-09-16 15:48:28 +0200
committerSimon Eisenmann <simon@struktur.de>2016-09-16 16:11:01 +0200
commit1e9d52304633eed8ad97a1764f4a19cbc6c2b9ed (patch)
tree68d7ba878714b0cc50180c959596b53b5ef7e5da /core/js/js.js
parentfcc91cbc494836766b545c320fe4c22e02579ec8 (diff)
downloadnextcloud-server-1e9d52304633eed8ad97a1764f4a19cbc6c2b9ed.tar.gz
nextcloud-server-1e9d52304633eed8ad97a1764f4a19cbc6c2b9ed.zip
Return '' instead of 'null'
This commit changes the behavior of getURLParameter(name) to return an empty string when the parameter is not set or has empty value. Before it returned 'null' as string.
Diffstat (limited to 'core/js/js.js')
-rw-r--r--core/js/js.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/js/js.js b/core/js/js.js
index c7a06b85e53..0a83f1104aa 100644
--- a/core/js/js.js
+++ b/core/js/js.js
@@ -1723,7 +1723,7 @@ function formatDate(timestamp){
*/
function getURLParameter(name) {
return decodeURI(
- (RegExp(name + '=' + '(.+?)(&|$)').exec(location.search) || [, null])[1]
+ (RegExp(name + '=' + '(.+?)(&|$)').exec(location.search) || [, ''])[1]
);
}