We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 75903eb commit 5bb8a1aCopy full SHA for 5bb8a1a
js/dataTables.fixedHeader.js
@@ -519,7 +519,11 @@ $.extend(FixedHeader.prototype, {
519
: null;
520
var scrollBody = $($(this.s.dt.table().node()).parent());
521
522
- if (mode === 'in-place') {
+ if (mode === this.s[item + 'Mode']) {
523
+ // Skip if already the current mode
524
+ return;
525
+ }
526
+ else if (mode === 'in-place') {
527
// Insert the header back into the table's real header
528
if (itemDom.placeholder) {
529
itemDom.placeholder.remove();
@@ -528,8 +532,7 @@ $.extend(FixedHeader.prototype, {
532
533
if (item === 'header') {
530
534
itemDom.host.prepend(tablePart);
531
- }
- else {
535
+ } else {
536
itemDom.host.append(tablePart);
537
}
538
0 commit comments