swte

Cache Jet Menu API requests

Feb 4th, 2021 (edited)
272
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.29 KB | None | 0 0
  1. /**
  2.  * Plugin Name: Swift Performance Tweaks
  3.  */
  4.  
  5. add_filter('swift_performance_is_cacheable_dynamic', function($result){
  6.     if (isset($_SERVER['REQUEST_URI']) && strpos('wp-json/jet-menu-api/v1/elementor-template', $_SERVER['REQUEST_URI']) !== false){
  7.         return true;
  8.     }
  9.     return $result;
  10. });
Add Comment
Please, Sign In to add comment