]> git.ipfire.org Git - thirdparty/patchwork.git/commit
templates: Avoid recursive call
authorStephen Finucane <stephen@that.guru>
Mon, 1 Oct 2018 21:36:41 +0000 (22:36 +0100)
committerStephen Finucane <stephen@that.guru>
Mon, 1 Oct 2018 21:51:25 +0000 (22:51 +0100)
commit7f8254c6f1c1fb1e97f03b37c741c557f5adaa8f
tree458bf7edb3e2989e18ba04cd2041fbabcc452848
parente8cc6f8d7b17eae8783432161c7ad76a939aa43d
templates: Avoid recursive call

We had registered an event handler on a checkbox in table header which
would call a function, 'checkboxes', on all checkboxes within that
table. This function, in turn, causes does its work and then triggers
event handlers for all modified checkboxes which include the original
table header checkbox. This resulted in the original event calling
itself recursively.

Resolve this by only modifying the checkboxes in the table body.

Signed-off-by: Stephen Finucane <stephen@that.guru>
Fixes: 44fe7bae ("js: Allow shift-select of checkboxes")
(cherry picked from commit ae154148c78a75ff73c3c22f0ff0c6b3a3d01408)
patchwork/templates/patchwork/patch-list.html