Skip to content

Commit

Permalink
Merge pull request #531 from frank-weinberg/bugfix/total-penalties
Browse files Browse the repository at this point in the history
Fix total penalty count
  • Loading branch information
frank-weinberg authored Sep 18, 2022
2 parents 4c701d7 + 3a1ec48 commit 9c908d9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions html/components/plt-input.js
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ function preparePltInputTable(element, gameId, teamId, mode, statsbookPeriod, al
if (penaltyPeriod === statsbookPeriod) {
penaltyBox.text(code);
} else {
penaltyBox.html(''); //   would confuse the forumla to calculate number of penalties.
penaltyBox.html(''); //   would confuse the formula to calculate number of penalties.
}
} else {
penaltyBox.text(code);
Expand Down Expand Up @@ -305,7 +305,7 @@ function preparePltInputTable(element, gameId, teamId, mode, statsbookPeriod, al
tbody.children('.Skater[id=' + s + ']').toggleClass('Warn2', cnt === limit - 1 && !fo_exp);
tbody.children('.Skater[id=' + s + ']').toggleClass('Warn3', cnt >= limit || fo_exp);

if (p !== 0) {
if (p != 0) {
if (oldId == null && newId != null) {
totalPenaltyCount++;
} else if (oldId != null && newId == null) {
Expand Down

0 comments on commit 9c908d9

Please sign in to comment.