Skip to content
Snippets Groups Projects
Commit c4e934e6 authored by Ere Maijala's avatar Ere Maijala Committed by Chris Hallberg
Browse files

Send lbreferer query param only if _currentUrl is set. (#1255)

parent d4b4f4cd
Branches
Tags
No related merge requests found
......@@ -134,7 +134,10 @@ VuFind.register('lightbox', function Lightbox() {
obj.url = parts[0].indexOf('?') < 0
? parts[0] + '?'
: parts[0] + '&';
obj.url += 'layout=lightbox&lbreferer=' + encodeURIComponent(_currentUrl);
obj.url += 'layout=lightbox';
if (_currentUrl) {
obj.url += '&lbreferer=' + encodeURIComponent(_currentUrl);
}
obj.url += parts.length < 2 ? '' : '#' + parts[1];
}
_xhr = $.ajax(obj);
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment