Skip to content

Commit 6e300b2

Browse files
authored
Update client.js
1 parent ac02814 commit 6e300b2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/kit/src/runtime/client/client.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2505,7 +2505,7 @@ function _start_router() {
25052505
if (history_index === current_history_index) return;
25062506

25072507
const scroll = scroll_positions[history_index];
2508-
const state = unstringify(event.state[STATES_KEY], app.hooks.transport) ?? {};
2508+
const state = event.state[STATES_KEY] ? unstringify(event.state[STATES_KEY], app.hooks.transport) : {};
25092509
const url = new URL(event.state[PAGE_URL_KEY] ?? location.href);
25102510
const navigation_index = event.state[NAVIGATION_INDEX];
25112511
const is_hash_change = current.url ? strip_hash(location) === strip_hash(current.url) : false;

0 commit comments

Comments
 (0)