fix specs

This commit is contained in:
ad1992 2022-04-26 12:02:50 +05:30
parent 1ca56204b1
commit 1edde7291c
2 changed files with 2 additions and 5 deletions

View File

@ -151,7 +151,6 @@ export const actionFinalize = register({
} else {
activeTool.type = "selection";
}
return {
elements: newElements,
appState: {
@ -162,10 +161,7 @@ export const actionFinalize = register({
appState.activeTool.type === "freedraw") &&
multiPointElement
? appState.activeTool
: {
...appState.activeTool,
activeTool,
},
: activeTool,
draggingElement: null,
multiElement: null,
editingElement: null,

View File

@ -263,6 +263,7 @@ export const restoreAppState = (
const activeTool: any = {
lastActiveToolBeforeEraser: null,
locked: nextAppState.activeTool.locked ?? false,
type: "selection",
};
if (AllowedExcalidrawActiveTools[nextAppState.activeTool.type]) {
if (nextAppState.activeTool.type === "custom") {