File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -257,18 +257,18 @@ class DraftailEditor extends Component<Props, State> {
257257
258258 this . renderSource = this . renderSource . bind ( this ) ;
259259
260- const { editorState : editorStateProp , rawContentState } = props ;
260+ const { editorState , rawContentState } = props ;
261261
262262 this . state = {
263263 readOnlyState : false ,
264264 hasFocus : false ,
265265 sourceOptions : null ,
266266 } ;
267267
268- // If editorState is not used as a prop, create it in local state from rawContentState.
269- if ( editorStateProp !== null ) {
268+ if ( editorState !== null ) {
270269 this . getEditorState = this . getEditorStateProp . bind ( this ) ;
271270 } else {
271+ // If editorState is not used as a prop, create it in local state from rawContentState.
272272 this . state . editorState = createEditorStateFromRaw ( rawContentState ) ;
273273 this . getEditorState = this . getEditorStateState . bind ( this ) ;
274274 }
You can’t perform that action at this time.
0 commit comments