Skip to content

Conversation

@akulistus
Copy link

@akulistus akulistus commented Dec 29, 2025

Problem:
If readOnly is initially set to true, Console tab displays warning:
EventDispatcher .off(): there is no subscribers for event "editor mobile layout toggled". Probably, .off() called before .on().

Issue:
#2772

Solution:
Add a guard to prevent unsubscribing from an event that was never subscribed when initial read-only mode is set to true.

this.readOnlyEnabled = state;

/**
* Do not render UI if state is read-only and it's initial call
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what does it mean "do not render UI" ? please, update jsdoc to make it more straightforward

@akulistus akulistus requested a review from neSpecc December 29, 2025 23:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants