Skip to content

Commit 2091e98

Browse files
committed
Fix incorrect query format being selected on page load with fragments
1 parent 3b08336 commit 2091e98

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ldf-client-ui.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ if (typeof global.process === 'undefined')
209209
$queries.chosen({ skip_no_results: true, placeholder_text: ' ' });
210210
$queries.change(function (query) {
211211
var queryContext = $queries.find(':selected').attr('queryContext');
212-
if ((options.query !== $queries.val() || options.queryContext !== queryContext) && (query = $queries.val())) {
212+
if ((options.query !== $queries.val() || (options.queryContext && options.queryContext !== queryContext)) && (query = $queries.val())) {
213213
// Set the query text
214214
self._setOption('queryFormat', $queries.find(':selected').attr('queryFormat'));
215215
if ($queryContextsIndexed[options.queryFormat])

0 commit comments

Comments
 (0)