We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ce8e410 commit 914e6ebCopy full SHA for 914e6eb
src/seed-text-view.ts
@@ -111,7 +111,7 @@ export class SeedTextView extends windowMixin(storeConsumerMixin(LitElement)) {
111
predicate: (_action: UnknownAction, currentState, previousState): boolean => {
112
return this.textId !== undefined &&
113
currentState.texts.hasOwnProperty(this.textId) &&
114
- (currentState.texts[this.textId].doc !== previousState.texts[this.textId]?.doc ?? "unknown");
+ (currentState.texts[this.textId].doc !== (previousState.texts?.[this.textId]?.doc ?? "unknown"));
115
},
116
effect: (_action, listenerApi): void => {
117
this.doc = listenerApi.getState().texts[this.textId ?? "_"].doc;
0 commit comments