Changeset 2452074
- Timestamp:
- 01/07/2021 05:33:06 PM (5 years ago)
- Location:
- post-status-indicator/trunk
- Files:
-
- 3 edited
-
post-status-indicator.php (modified) (5 diffs)
-
screenshot-1.jpg (modified) (previous)
-
screenshot-2.jpg (modified) (previous)
Legend:
- Unmodified
- Added
- Removed
-
post-status-indicator/trunk/post-status-indicator.php
r2448846 r2452074 51 51 52 52 static $instance = false; 53 private $version; 53 54 54 55 private function __construct() { … … 58 59 add_action( 'admin_menu', array( $this, 'psi_options_page' ) ); 59 60 add_action( 'rest_api_init', array( $this, 'rest_api_init' ) ); 61 62 $this->version = PSI_VERSION; 63 64 if( defined('WP_DEBUG') && true === WP_DEBUG ){ 65 $this->version = time(); 66 } 60 67 } 61 68 … … 79 86 } 80 87 81 $version = PSI_VERSION; 82 83 if( defined('WP_DEBUG') && true === WP_DEBUG ){ 84 $version = time(); 85 } 86 87 wp_enqueue_script('psi-dashboard', PSI_PLUGIN_URL . 'psi-dashboard/dist/js/post-status-indicator.js', array( 'wp-api', 'wp-i18n', 'wp-components', 'wp-element' ), $version, true); 88 wp_enqueue_script('psi-dashboard', PSI_PLUGIN_URL . 'psi-dashboard/dist/js/post-status-indicator.js', array( 'wp-api', 'wp-i18n', 'wp-components', 'wp-element' ), $this->version, true); 88 89 // wp_enqueue_style('psi-dashboard', PSI_PLUGIN_URL . 'psi-dashboard/dist/css/style.bundle.css', array(), PSI_VERSION); 89 90 … … 104 105 ); 105 106 wp_localize_script('psi-dashboard', 'psi_config', $config); 106 wp_enqueue_style( 'post-status-indicator', PSI_PLUGIN_URL . 'css/post-status-indicator.css', array( 'wp-components', 'dashicons' ), $ version );107 wp_enqueue_style( 'post-status-indicator', PSI_PLUGIN_URL . 'css/post-status-indicator.css', array( 'wp-components', 'dashicons' ), $this->version ); 107 108 108 109 } … … 118 119 } 119 120 120 wp_register_style( 'post-status-indicator', PSI_PLUGIN_URL . 'css/post-status-indicator.css', array( 'wp-components' ), $ version );121 wp_register_style( 'post-status-indicator', PSI_PLUGIN_URL . 'css/post-status-indicator.css', array( 'wp-components' ), $this->version ); 121 122 wp_enqueue_style( 'post-status-indicator' ); 122 123
Note: See TracChangeset
for help on using the changeset viewer.