We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
Total Complexity | 4 |
Complexity/F | 1 |
Lines of Code | 37 |
Function Count | 4 |
Duplicated Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | /** |
||
11 | $("#tx-dlf-search-query").attr({ |
||
12 | 'autocomplete': "off", |
||
13 | 'role': "textbox", |
||
14 | 'aria-autocomplete': "list", |
||
15 | 'aria-haspopup': "true" |
||
16 | }); |
||
17 | |||
18 | $( |
||
19 | function() { |
||
20 | // jQuery autocomplete integration |
||
21 | $("#tx-dlf-search-query").autocomplete({ |
||
22 | source: function(request, response) { |
||
23 | return $.post( |
||
24 | "/", |
||
25 | { |
||
26 | eID: "tx_dlf_search_suggest", |
||
27 | q: encodeURIComponent(request.term.toLowerCase()), |
||
28 | encrypted: $("input[name='tx_dlf[encrypted]']").val(), |
||
29 | hashed: $("input[name='tx_dlf[hashed]']").val() |
||
30 | }, |
||
31 | function(data) { |
||
32 | var result = []; |
||
33 | var option = ""; |
||
34 | $("arr[name='suggestion'] str", data).each(function(i) { |
||
|
|||
35 | option = $(this).text(); |
||
36 | option = option.replace(/(\?|!|:)/g, "\\\$1"); |
||
37 | result.push(option); |
||
38 | }); |
||
39 | return response(result); |
||
40 | }, |
||
41 | "xml"); |
||
42 | }, |
||
43 | minLength: 3, |
||
44 | appendTo: "#tx-dlf-search-suggest" |
||
45 | }); |
||
46 | } |
||
47 | ); |
||
48 |
This check looks for parameters in functions that are not used in the function body and are not followed by other parameters which are used inside the function.