Skip to content

Commit

Permalink
Merge pull request #429 from Kernel360/428-fix-fix-not-recording-lear…
Browse files Browse the repository at this point in the history
…ning-progress-rate-on-reading-page

fix : 기존 learningRate보다 작을 때만 learningRate업데이트를 하고 있던 문제 해결
  • Loading branch information
smosco authored Dec 17, 2024
2 parents 22698c8 + d85aee4 commit 9a197f4
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/hooks/useUpdateLearningProgressOnUnmount.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,7 @@ export const useUpdateLearningProgressOnUnmount = (
const scrollProgressRef = useRef<number>(progress);

useEffect(() => {
if (scrollProgressRef.current < progress) {
scrollProgressRef.current = progress;
}
scrollProgressRef.current = progress;
}, [progress]);

useEffect(() => {
Expand Down

0 comments on commit 9a197f4

Please sign in to comment.