1
0
mirror of https://git.tt-rss.org/git/tt-rss.git synced 2025-12-13 06:35:55 +00:00

reduce overhead in hash set/get

This commit is contained in:
Andrew Dolgov
2021-03-06 22:41:46 +03:00
parent 7b0b5b55c7
commit 1d9fa2a42e
3 changed files with 21 additions and 21 deletions

View File

@@ -69,15 +69,3 @@ require(["dojo/_base/kernel",
});
});
/* exported hash_get */
function hash_get(key) {
const obj = dojo.queryToObject(window.location.hash.substring(1));
return obj[key];
}
/* exported hash_set */
function hash_set(key, value) {
const obj = dojo.queryToObject(window.location.hash.substring(1));
obj[key] = value;
window.location.hash = dojo.objectToQuery(obj);
}