File tree Expand file tree Collapse file tree 2 files changed +0
-12
lines changed Expand file tree Collapse file tree 2 files changed +0
-12
lines changed Original file line number Diff line number Diff line change 1
1
var invariant = require ( 'react/lib/invariant' ) ;
2
- var canUseDOM = require ( 'react/lib/ExecutionEnvironment' ) . canUseDOM ;
3
2
var LocationActions = require ( '../actions/LocationActions' ) ;
4
3
var Path = require ( '../utils/Path' ) ;
5
4
@@ -8,11 +7,6 @@ var Path = require('../utils/Path');
8
7
* query string.
9
8
*/
10
9
function getHashPath ( ) {
11
- invariant (
12
- canUseDOM ,
13
- 'getHashPath needs a DOM'
14
- ) ;
15
-
16
10
return Path . decode (
17
11
// We can't use window.location.hash here because it's not
18
12
// consistent across browsers - Firefox will pre-decode it!
Original file line number Diff line number Diff line change 1
1
var invariant = require ( 'react/lib/invariant' ) ;
2
- var canUseDOM = require ( 'react/lib/ExecutionEnvironment' ) . canUseDOM ;
3
2
var LocationActions = require ( '../actions/LocationActions' ) ;
4
3
var Path = require ( '../utils/Path' ) ;
5
4
6
5
/**
7
6
* Returns the current URL path from `window.location`, including query string.
8
7
*/
9
8
function getWindowPath ( ) {
10
- invariant (
11
- canUseDOM ,
12
- 'getWindowPath needs a DOM'
13
- ) ;
14
-
15
9
return Path . decode (
16
10
window . location . pathname + window . location . search
17
11
) ;
You can’t perform that action at this time.
0 commit comments