Skip to content

Commit

Permalink
fix watcher bug
Browse files Browse the repository at this point in the history
  • Loading branch information
probablyjassin committed Nov 12, 2024
1 parent 6757e9e commit 9f05fb1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pages/stundenplan.vue
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ const password = useCookie("password");
const isLoggedIn = useState("isLoggedIn", (() => false))
const today = new Date().setHours(0, 0, 0, 0);
const page = ref(1);
const page = useState("page", (() => 1));
const data = useState('stundenplan', (() => []));
Expand Down Expand Up @@ -88,7 +88,7 @@ watch(data, (newVal) => {
}
});
watch(groupedByDay.value, (newVal) => {
watch(groupedByDay, (newVal) => {
const todayIndex = Object.keys(newVal).indexOf(today.toString());
if (todayIndex !== -1) {
page.value = todayIndex + 1;
Expand Down

0 comments on commit 9f05fb1

Please sign in to comment.