Skip to content
This repository has been archived by the owner on Feb 22, 2022. It is now read-only.

Add the plugin version when enqueueing styles, for cache busting. #79

Merged
merged 1 commit into from
Apr 16, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ function wp_autoupdates_enqueues( $hook ) {
if ( ! in_array( $hook, array( 'plugins.php', 'themes.php', 'update-core.php' ) ) ) {
return;
}
wp_register_style( 'wp-autoupdates', plugin_dir_url( __FILE__ ) . 'css/wp-autoupdates.css', array() );
wp_register_style( 'wp-autoupdates', plugin_dir_url( __FILE__ ) . 'css/wp-autoupdates.css', array(), WP_AUTO_UPDATES_VERSION );
wp_enqueue_style( 'wp-autoupdates' );

// Update core screen JS hack (due to lack of filters).
Expand Down
1 change: 1 addition & 0 deletions wp-autoupdates.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
die( 'Invalid request.' );
}

define( 'WP_AUTO_UPDATES_VERSION', '0.5.0' );

/**
* Load only when needed.
Expand Down