Skip to content

Commit

Permalink
Fix module toggle console error (#21071)
Browse files Browse the repository at this point in the history
  • Loading branch information
karthikax authored Sep 14, 2021
1 parent b30a385 commit 8b57b40
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ let hasGenerateRun = false;
* runs if the module is enabled again.
*/
modules.subscribe( modulesState => {
if ( ! modulesState[ 'critical-css' ].enabled ) {
if ( ! modulesState[ 'critical-css' ] || ! modulesState[ 'critical-css' ].enabled ) {
hasGenerateRun = false;
}
} );
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fixed

Fix console error on critical-css module subscription status

0 comments on commit 8b57b40

Please sign in to comment.