This commit gets rid of log-level data in localStorage which in some extreme cases could fill up the entire localStorage making the app unusable Followup to https://github.com/matrix-org/matrix-js-sdk/pull/1880
12 lines
397 B
TypeScript
12 lines
397 B
TypeScript
/**
|
|
* Because we've been saving a lot of additional logger data in the localStorage for no particular reason
|
|
* we need to, hopefully, unbrick user's devices by geting rid of unnecessary data.
|
|
* */
|
|
|
|
if (window.localStorage) {
|
|
Object.keys(window.localStorage).forEach(key => {
|
|
if (key.indexOf('loglevel:') === 0) {
|
|
window.localStorage.removeItem(key);
|
|
}
|
|
});
|
|
}
|