When to use removeEditorPanel()

I think this is due to how you’ve destructured it out. I believe dispatch works as a realtime “action”. So you need call dispatch() when you want to remove the panel.

Try this:

const { dispatch } = wp.data;
dispatch( 'core/edit-post' ).removeEditorPanel( 'discussion-panel' )

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)