Skip to content
Permalink
Browse files

Dequeue dashicons for logged out users

  • Loading branch information...
jacklenox committed Jul 11, 2018
1 parent add2d9f commit 0a086e970e7db8cc67490857a44a7c09f967411d
Showing with 8 additions and 0 deletions.
  1. +8 −0 functions.php
@@ -157,3 +157,11 @@ function susty_register_query_var( $vars ) {
}
return $path;
});
// Remove dashicons in frontend for unauthenticated users
add_action( 'wp_enqueue_scripts', 'susty_dequeue_dashicons' );
function susty_dequeue_dashicons() {
if ( ! is_user_logged_in() ) {
wp_deregister_style( 'dashicons' );
}
}

0 comments on commit 0a086e9

Please sign in to comment.
You can’t perform that action at this time.