Ticket #50849: 50849.diff
File 50849.diff, 1.6 KB (added by , 4 years ago) |
---|
-
src/wp-admin/includes/class-plugin-upgrader.php
132 132 add_action( 'upgrader_process_complete', 'wp_clean_plugins_cache', 9, 0 ); 133 133 } 134 134 135 $type = 'install'; 136 137 if ( ! empty( $this->skin->overwrite ) ) { 138 if ( in_array( $this->skin->overwrite, array( 'update-plugin', 'downgrade-plugin' ), true ) ) { 139 $type = $this->skin->overwrite; 140 } 141 } 142 135 143 $this->run( 136 144 array( 137 145 'package' => $package, … … 140 148 'clear_working' => true, 141 149 'hook_extra' => array( 142 150 'type' => 'plugin', 143 'action' => 'install',151 'action' => $type, 144 152 ), 145 153 ) 146 154 ); -
src/wp-admin/includes/class-theme-upgrader.php
245 245 add_action( 'upgrader_process_complete', 'wp_clean_themes_cache', 9, 0 ); 246 246 } 247 247 248 $type = 'install'; 249 250 if ( ! empty( $this->skin->overwrite ) ) { 251 if ( in_array( $this->skin->overwrite, array( 'update-theme', 'downgrade-theme' ), true ) ) { 252 $type = $this->skin->overwrite; 253 } 254 } 255 248 256 $this->run( 249 257 array( 250 258 'package' => $package, … … 253 261 'clear_working' => true, 254 262 'hook_extra' => array( 255 263 'type' => 'theme', 256 'action' => 'install',264 'action' => $type, 257 265 ), 258 266 ) 259 267 );