Skip to content

Offline, privacy-first grammar checker. Fast, open-source, Rust-powered

fix: not editing summary titles

Elijah Potterbf9b9b9ec4ed
diff --git a/src/harper/DataBlock.ts b/src/harper/DataBlock.ts
index 909a5c7fe..bc2ba9bca 100644
--- a/src/harper/DataBlock.ts
+++ b/src/harper/DataBlock.ts
@@ -24,8 +24,16 @@ export default class DataBlock {
const { updateBlockAttributes } =
dispatch( 'core/block-editor' );
+ console.log(
+ `Updating ${ this.getClientId() } to "${ newContent }"`
+ );
+
+ let attributeName =
+ cont.getAttribute( 'data-wp-block-attribute-key' ) ??
+ 'content';
+
await updateBlockAttributes( this.getClientId(), {
- content: newContent,
+ [ attributeName ]: newContent,
} );
} )
);