Skip to content

Commit 342efc6

Browse files
debug2604debug2604
authored andcommitted
deleted old code in 0.js
1 parent 576dc5a commit 342efc6

1 file changed

Lines changed: 0 additions & 5 deletions

File tree

  • Sprint-3/1-key-errors

‎Sprint-3/1-key-errors/0.js‎

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,6 @@
44
// call the function capitalise with a string input
55
// interpret the error message and figure out why an error is occurring
66

7-
function capitalise(str) {
8-
let str = `${str[0].toUpperCase()}${str.slice(1)}`;
9-
return str;
10-
}
11-
127
// =============> The result was a Syntax error because str has been declared as parameter of function captialise before let reassign str.
138
// =============>
149
function capitalise(str) {

0 commit comments

Comments
 (0)