Skip to content

Commit 063968e

Browse files
committed
feat: reset audio playback position when pausing alarm
1 parent b33fd6a commit 063968e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Sprint-3/alarmclock/alarmclock.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,8 +72,8 @@ function playAlarm() {
7272
function pauseAlarm() {
7373
audio.pause();
7474
stopAudio.play();
75+
audio.currentTime = 0;
7576
clearInterval(countdown);
76-
// document.body.style.backgroundColor = "white";
7777
}
7878

7979
window.onload = setup;

0 commit comments

Comments
 (0)