Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit dc9bca2

Browse files
committed
Patch blockStyleFn
1 parent 77577e2 commit dc9bca2

File tree

1 file changed

+1
-1
lines changed
  • draft-js-plugins-editor/src/Editor

1 file changed

+1
-1
lines changed

draft-js-plugins-editor/src/Editor/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ class PluginEditor extends Component {
170170
for (const plugin of plugins) {
171171
if (typeof plugin[methodName] !== 'function') continue;
172172
const result = plugin[methodName](...newArgs);
173-
if (result !== undefined) {
173+
if (result !== undefined && result !== null) {
174174
styles = (styles ? (`${styles} `) : '') + result;
175175
}
176176
}

0 commit comments

Comments
 (0)