Skip to content

Commit 355c2e3

Browse files
authored
Merge pull request #2466 from aliaghdam/master
fix undefined to pass test
2 parents 0806399 + 6975a01 commit 355c2e3

File tree

1 file changed

+1
-1
lines changed
  • 1-js/05-data-types/10-destructuring-assignment/6-max-salary/_js.view

1 file changed

+1
-1
lines changed

1-js/05-data-types/10-destructuring-assignment/6-max-salary/_js.view/solution.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ function topSalary(salaries) {
44
let maxName = null;
55

66
for(const [name, salary] of Object.entries(salaries)) {
7-
if (max < salary) {
7+
if (maxSalary < salary) {
88
maxSalary = salary;
99
maxName = name;
1010
}

0 commit comments

Comments
 (0)