mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-02-24 23:48:13 -05:00
Koenig - Fixed "set on destroyed object" error
refs https://github.com/TryGhost/Ghost/issues/9623 - the `{{koenig-toolbar}} `didReceiveAttrs` hook was triggering an async action when the component was being destroyed so a guard is needed around the call to `set` in the `_hideToolbar` method
This commit is contained in:
parent
7846192ac3
commit
b0d778a5dc
1 changed files with 3 additions and 1 deletions
|
@ -227,7 +227,9 @@ export default Component.extend({
|
||||||
},
|
},
|
||||||
|
|
||||||
_hideToolbar() {
|
_hideToolbar() {
|
||||||
this.set('showToolbar', false);
|
if (!this.isDestroyed || !this.isDestroying) {
|
||||||
|
this.set('showToolbar', false);
|
||||||
|
}
|
||||||
this._lastRange = null;
|
this._lastRange = null;
|
||||||
this._removeMousemoveHandler();
|
this._removeMousemoveHandler();
|
||||||
},
|
},
|
||||||
|
|
Loading…
Add table
Reference in a new issue