fix empty hash
parent
f3cf50515d
commit
a7a65aceb2
|
@ -2,6 +2,8 @@ import LZString from "lz-string";
|
||||||
|
|
||||||
export function read() {
|
export function read() {
|
||||||
const hash = document.location.hash.slice(1);
|
const hash = document.location.hash.slice(1);
|
||||||
|
if (!hash) return {};
|
||||||
|
|
||||||
// backwards support for old json encoded URIComponent
|
// backwards support for old json encoded URIComponent
|
||||||
const decode =
|
const decode =
|
||||||
hash.indexOf("%7B%22") !== -1
|
hash.indexOf("%7B%22") !== -1
|
||||||
|
|
Loading…
Reference in New Issue