Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Commit

Permalink
Fix update_script_data_cache
Browse files Browse the repository at this point in the history
  • Loading branch information
mikejolley committed Jun 1, 2023
1 parent f1e77d7 commit 74bf448
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/Assets/Api.php
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,9 @@ private function get_cached_script_data() {
* Store all cached script data in the transient cache.
*/
public function update_script_data_cache() {
if ( is_null( $this->script_data ) || $this->disable_cache ) {
return;
}
set_transient(
'woocommerce_blocks_asset_api_script_data',
wp_json_encode(
Expand Down

0 comments on commit 74bf448

Please sign in to comment.