FIX: Don't call cooked decorators in composer if cooked is unchanged
If cooked is unchanged, ember will not re-render the preview area, so we should not re-run the post-processing decorators. This can cause issues when decorateCooked functions are not idempotent.
This commit is contained in:
parent
f67e7d2fad
commit
9e98c02dd7
|
@ -367,6 +367,9 @@ export default Component.extend({
|
|||
if (this.isDestroyed) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.preview === cooked) return;
|
||||
|
||||
this.set("preview", cooked);
|
||||
schedule("afterRender", () => {
|
||||
if (this._state !== "inDOM") {
|
||||
|
|
Loading…
Reference in New Issue