Skip to content

Commit 0e0d115

Browse files
committed
Merge pull request #251 from ganmor/debug-session-name
fix regexp to extract debug session name
2 parents a87564c + 890ecf8 commit 0e0d115

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

docs/Walkthrough.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ const enhancer = compose(
121121
function getDebugSessionKey() {
122122
// You can write custom logic here!
123123
// By default we try to read the key from ?debug_session=<key> in the address bar
124-
const matches = window.location.href.match(/[?&]debug_session=([^&]+)\b/);
124+
const matches = window.location.href.match(/[?&]debug_session=([^&#]+)\b/);
125125
return (matches && matches.length > 0)? matches[1] : null;
126126
}
127127

examples/counter/src/store/configureStore.dev.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const enhancer = compose(
99
DevTools.instrument(),
1010
persistState(
1111
window.location.href.match(
12-
/[?&]debug_session=([^&]+)\b/
12+
/[?&]debug_session=([^&#]+)\b/
1313
)
1414
)
1515
);

examples/todomvc/store/configureStore.dev.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ const enhancer = compose(
77
DevTools.instrument(),
88
persistState(
99
window.location.href.match(
10-
/[?&]debug_session=([^&]+)\b/
10+
/[?&]debug_session=([^&#]+)\b/
1111
)
1212
)
1313
);

0 commit comments

Comments
 (0)