Changeset 2767085
- Timestamp:
- 08/05/2022 11:11:36 PM (4 years ago)
- Location:
- word-count-analysis/trunk
- Files:
-
- 2 edited
-
wca_hook.php (modified) (1 diff)
-
word-count-analysis.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
word-count-analysis/trunk/wca_hook.php
r2767050 r2767085 210 210 add_action('wp_dashboard_setup', 'wca_add_dashboard_widgets'); 211 211 212 add_action( 'upgrader_process_complete', 'wca_upgrade_function',10, 2);213 214 function wca_upgrade_function( $upgrader_object, $options ) {215 $current_plugin_path_name = plugin_basename( __FILE__ );216 217 if ($options['action'] == 'update' && $options['type'] == 'plugin' ) {218 foreach($options['plugins'] as $each_plugin) {219 if ($each_plugin==$current_plugin_path_name) {220 $updated = update_option('wca_version', WORD_COUNT_ANALYSIS_VERSION);221 }222 }223 }224 } -
word-count-analysis/trunk/word-count-analysis.php
r2767054 r2767085 69 69 } 70 70 71 add_action('upgrader_process_complete', 'wca_upgrade_function', 10, 2); 72 73 function wca_upgrade_function($upgrader_object, $options) 74 { 75 $current_plugin_path_name = plugin_basename(__FILE__); 76 77 if ($options['action'] == 'update' && $options['type'] == 'plugin') { 78 foreach ($options['plugins'] as $each_plugin) { 79 if ($each_plugin == $current_plugin_path_name) { 80 $updated = update_option('wca_version', WORD_COUNT_ANALYSIS_VERSION); 81 } 82 } 83 } 84 }
Note: See TracChangeset
for help on using the changeset viewer.