Remove element shape object from local storage save (#336)
This commit is contained in:
parent
bc909b76da
commit
ba8bc10431
@ -187,7 +187,9 @@ export function restoreFromLocalStorage() {
|
||||
let elements = [];
|
||||
if (savedElements) {
|
||||
try {
|
||||
elements = JSON.parse(savedElements);
|
||||
elements = JSON.parse(savedElements).map(
|
||||
({ shape, ...element }: ExcalidrawElement) => element
|
||||
);
|
||||
} catch (e) {
|
||||
// Do nothing because elements array is already empty
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user