wp/wp-admin/includes/theme-install.php
changeset 16 a86126ab1dd4
parent 9 177826044cd9
child 18 be944660c56a
--- a/wp/wp-admin/includes/theme-install.php	Tue Oct 22 16:11:46 2019 +0200
+++ b/wp/wp-admin/includes/theme-install.php	Tue Dec 15 13:49:49 2020 +0100
@@ -55,14 +55,15 @@
  *
  * @since 2.8.0
  *
- * @deprecated since 3.1.0 Use get_theme_feature_list() instead.
+ * @deprecated 3.1.0 Use get_theme_feature_list() instead.
  *
  * @return array
  */
 function install_themes_feature_list() {
 	_deprecated_function( __FUNCTION__, '3.1.0', 'get_theme_feature_list()' );
 
-	if ( ! $cache = get_transient( 'wporg_theme_feature_list' ) ) {
+	$cache = get_transient( 'wporg_theme_feature_list' );
+	if ( ! $cache ) {
 		set_transient( 'wporg_theme_feature_list', array(), 3 * HOUR_IN_SECONDS );
 	}
 
@@ -178,11 +179,11 @@
  */
 function install_themes_upload() {
 	?>
-<p class="install-help"><?php _e( 'If you have a theme in a .zip format, you may install it by uploading it here.' ); ?></p>
+<p class="install-help"><?php _e( 'If you have a theme in a .zip format, you may install or update it by uploading it here.' ); ?></p>
 <form method="post" enctype="multipart/form-data" class="wp-upload-form" action="<?php echo self_admin_url( 'update.php?action=upload-theme' ); ?>">
 	<?php wp_nonce_field( 'theme-upload' ); ?>
 	<label class="screen-reader-text" for="themezip"><?php _e( 'Theme zip file' ); ?></label>
-	<input type="file" id="themezip" name="themezip" />
+	<input type="file" id="themezip" name="themezip" accept=".zip"/>
 	<?php submit_button( __( 'Install Now' ), '', 'install-theme-submit', false ); ?>
 </form>
 	<?php