Skip to content

Commit d9feb62

Browse files
authored
fix(curriculum): add more buffer time lab data conversion (freeCodeCamp#56606)
1 parent db9ffd2 commit d9feb62

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

curriculum/challenges/english/25-front-end-development/lab-date-conversion/66f686b8ebdb982fa8e14330.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,12 @@ assert.equal(currentDateOnly.toString(), expectedDateOnly.toString());
4343
You should have a variable named `currentDateFormat` that holds the current date in the format `Current Date and Time: <ddd> <MMM> <dd> <yyyy> <HH>:<mm>:<ss> <TIMEZONE>`.
4444

4545
```js
46-
const expectedDate = new Date();
4746
const expectedDateString = `Current Date and Time: `;
4847
assert.include(currentDateFormat, expectedDateString);
4948

5049
const currentTimestamp = new Date(currentDateFormat.replace(expectedDateString, '')).getTime();
51-
const expectedTimestamp = expectedDate.getTime();
52-
assert.approximately(currentTimestamp, expectedTimestamp, 1000);
50+
const expectedTimestamp = new Date().getTime();
51+
assert.approximately(currentTimestamp, expectedTimestamp, 2000);
5352
```
5453

5554
You should log the value of `currentDateFormat` to the console.

0 commit comments

Comments
 (0)