Skip to content

Commit e564805

Browse files
committed
Fix: deleted the extra lines.
1 parent cf67a9a commit e564805

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

Sprint-1/refactor/includes.js

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
// Refactor the implementation of includes to use a for...of loop
22

33
function includes(list, target) {
4-
if (list.length === 0) {
5-
return false;
6-
}
4+
75
for (const item of list) {
86
if (item === target) {
97
return true;

0 commit comments

Comments
 (0)