Skip to content

Commit 5e2c95c

Browse files
author
Henning Bredel
committed
Do not decrease TOTAL_FORMS counter
1 parent 38475fb commit 5e2c95c

1 file changed

Lines changed: 0 additions & 5 deletions

File tree

src/jquery.formset.js

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -91,13 +91,8 @@
9191
// and hide it, then let Django handle the deleting:
9292
del.val('on');
9393
row.hide();
94-
forms = $('.' + options.formCssClass).not(':hidden');
95-
totalForms.val(forms.length);
9694
} else {
9795
row.remove();
98-
// Update the TOTAL_FORMS count:
99-
forms = $('.' + options.formCssClass).not('.formset-custom-template');
100-
totalForms.val(forms.length);
10196
}
10297
for (var i=0, formCount=forms.length; i<formCount; i++) {
10398
// Apply `extraClasses` to form rows so they're nicely alternating:

0 commit comments

Comments
 (0)