Merge pull request #395 from kadimi/patch-38

Remove deprecated jQuery function `size`
This commit is contained in:
Brian Miyaji
2020-08-27 23:12:43 +10:00
committed by GitHub

View File

@@ -258,7 +258,7 @@ jQuery(document).ready(function($){
});
// Activate total stats calculator
if($(".sp-data-table .sp-total").size()) {
if($(".sp-data-table .sp-total").length) {
$(".sp-data-table .sp-post td input").on("keyup", function() {
$(this).closest(".sp-data-table").find(".sp-total td").eq($(this).parent().index()).find("input[data-sp-format=number][data-sp-total-type!=average]").trigger("updateTotal");
});