diff --git a/src/components/withLocation/withURLLocation.js b/src/components/withLocation/withURLLocation.js index 2a781edb..65ca216c 100644 --- a/src/components/withLocation/withURLLocation.js +++ b/src/components/withLocation/withURLLocation.js @@ -3,7 +3,7 @@ import { Location } from '@reach/router'; import queryString from 'query-string'; let search = - typeof location !== 'undefined' && location.search + typeof window !== 'undefined' && window.location.search ? queryString.parse(window.location.search) : {};