Changeset 57545 for trunk/src/wp-admin/includes/class-plugin-upgrader.php
- Timestamp:
- 02/06/2024 11:44:09 PM (8 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/class-plugin-upgrader.php
r57239 r57545 155 155 // Force refresh of plugin update information. 156 156 wp_clean_plugins_cache( $parsed_args['clear_update_cache'] ); 157 158 $all_plugin_data = get_option( 'plugin_data', array() ); 159 $plugin_file = $this->new_plugin_data['file']; 160 unset( $this->new_plugin_data['file'] ); 161 $all_plugin_data[ $plugin_file ] = $this->new_plugin_data; 162 update_option( 'plugin_data', $all_plugin_data ); 157 163 158 164 if ( $parsed_args['overwrite_package'] ) { … … 483 489 $info = get_plugin_data( $file, false, false ); 484 490 if ( ! empty( $info['Name'] ) ) { 485 $this->new_plugin_data = $info; 491 $basename = basename( $file ); 492 $dirname = basename( dirname( $file ) ); 493 494 if ( '.' === $dirname ) { 495 $plugin_file = $basename; 496 } else { 497 $plugin_file = "$dirname/$basename"; 498 } 499 $this->new_plugin_data = ( $info ); 500 $this->new_plugin_data['file'] = $plugin_file; 486 501 break; 487 502 }
Note: See TracChangeset
for help on using the changeset viewer.