From ca34257bd6c4c90544de3f576efbc607be7fb5d9 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Wed, 7 Jan 2015 23:42:48 +0000 Subject: [PATCH] Call the init() method for the upgrader in wp_can_install_language_pack() to avoid undefined index notices. props ocean90. fixes #30827 for trunk. git-svn-id: https://develop.svn.wordpress.org/trunk@31074 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/translation-install.php | 1 + 1 file changed, 1 insertion(+) diff --git a/src/wp-admin/includes/translation-install.php b/src/wp-admin/includes/translation-install.php index f3cc370ac4..66eb77ff56 100644 --- a/src/wp-admin/includes/translation-install.php +++ b/src/wp-admin/includes/translation-install.php @@ -229,6 +229,7 @@ function wp_can_install_language_pack() { require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php'; $skin = new Automatic_Upgrader_Skin; $upgrader = new Language_Pack_Upgrader( $skin ); + $upgrader->init(); $check = $upgrader->fs_connect( array( WP_CONTENT_DIR, WP_LANG_DIR ) );