Skip to content

Commit

Permalink
Declared var on the top
Browse files Browse the repository at this point in the history
  • Loading branch information
SharkyBytes committed Dec 30, 2024
1 parent 803fcdd commit b06f2c7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion openlibrary/plugins/openlibrary/js/editions-table/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ const DEFAULT_LENGTH = 3;
const LS_RESULTS_LENGTH_KEY = 'editions-table.resultsLength';

export function initEditionsTable() {
var rowCount;

$('#editions th.title').on('mouseover', function(){
if ($(this).hasClass('sorting_asc')) {
Expand Down Expand Up @@ -51,7 +52,7 @@ export function initEditionsTable() {
}
})

var rowCount = $('#editions tbody tr').length;
rowCount = $('#editions tbody tr').length;
let currentLength = Number(localStorage.getItem(LS_RESULTS_LENGTH_KEY)) || DEFAULT_LENGTH;

$('#editions').DataTable({
Expand Down

0 comments on commit b06f2c7

Please sign in to comment.