Advertisement
Guest User

Untitled

a guest
Apr 20th, 2019
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.77 KB | None | 0 0
  1. <?php
  2.  
  3. /*
  4. * Disable Redux Developer Mode dev_mode
  5. */
  6. function redux_disable_dev_mode_plugin( $redux ) {
  7. if ( ! function_exists( 'redux_disable_dev_mode_plugin' ) ) {
  8. if ( $redux->args['opt_name'] != 'redux_demo' ) {
  9. $redux->args['dev_mode'] = false;
  10. $redux->args['forced_dev_mode_off'] = false;
  11. }
  12. }
  13. }
  14. add_action( 'redux/construct', 'redux_disable_dev_mode_plugin' );
  15.  
  16. function gl_removeDemoModeLink() {
  17. if ( class_exists( 'ReduxFrameworkPlugin' ) ) {
  18. remove_filter( 'plugin_row_meta', array( ReduxFrameworkPlugin::get_instance(), 'plugin_metalinks' ), null, 2 );
  19. }
  20. if ( class_exists( 'ReduxFrameworkPlugin' ) ) {
  21. remove_action( 'admin_notices', array( ReduxFrameworkPlugin::get_instance(), 'admin_notices' ) );
  22. }
  23. }
  24. add_action( 'init', 'gl_removeDemoModeLink' );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement