Skip to content

Instantly share code, notes, and snippets.

@Alimir
Created September 27, 2022 08:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Alimir/59fed391ee3ed4117c59bb8bfaf4f947 to your computer and use it in GitHub Desktop.
Save Alimir/59fed391ee3ed4117c59bb8bfaf4f947 to your computer and use it in GitHub Desktop.
Fix compatibility problem with the 'Simple Custom CSS and JS' plugin
<?php
add_filter('ulf_enqueue_assets',function($enqueue){
// Global object containing current admin page
global $pagenow;
if ( 'post.php' === $pagenow && isset($_GET['post']) && 'custom-css-js' === get_post_type( $_GET['post'] ) ){
return false;
}
return $enqueue;
},10, 1);
@Alimir
Copy link
Author

Alimir commented Feb 15, 2024

we've already fixed this problem in the plugin and you don't need to use this anymore!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment