Skip to content
Snippets Groups Projects
Commit 41d1326d authored by Dyszczo's avatar Dyszczo
Browse files

Merge branch 'feature/fixes' into 'master'

Feature/fixes

See merge request !15
parents cb22bacc 2a233d0e
Branches
Tags
1 merge request!15Feature/fixes
Pipeline #8973 passed with warnings
## [3.0.2] - 2019-09-18
### Fixed
- Better error message display for temporary disabling
- Installation url
## [3.0.1] - 2019-09-18
### Fixed
- Better new error messages display
......
......@@ -224,7 +224,7 @@ if ( ! class_exists( 'WPDesk_Basic_Requirement_Checker' ) ) {
*
* @return string
*/
private function prepare_notice_message( $message ) {
protected function prepare_notice_message( $message ) {
return '<div class="error"><p>' . $message . '</p></div>';
}
......@@ -314,11 +314,11 @@ if ( ! class_exists( 'WPDesk_Basic_Requirement_Checker' ) ) {
$install_url = wp_nonce_url( self_admin_url( 'update.php?action=install-plugin&plugin=' . $slug ),
'install-plugin_' . $slug );
add_filter( 'plugins_api', function ( $api, $action, $args ) use ( $plugin_info ) {
add_filter( 'plugins_api', function ( $api, $action, $args ) use ( $plugin_info, $slug ) {
if ( 'plugin_information' !== $action ||
false !== $api ||
! isset( $args->slug ) ||
'wpdesk-helper' !== $args->slug
$slug !== $args->slug
) {
return $api;
}
......
......@@ -24,9 +24,9 @@ if ( ! class_exists( 'WPDesk_Basic_Requirement_Checker_With_Update_Disable' ) )
foreach ( $this->plugin_require as $name => $plugin_info ) {
if ( $this->is_currently_updated( $name ) ) {
$nice_name = $plugin_info[ self::PLUGIN_INFO_KEY_NICE_NAME ];
$this->notices[] = sprintf( __( 'The &#8220;%s&#8221; plugin disables temporarily as required %s plugin is being upgraded.',
$this->notices[] = $this->prepare_notice_message( sprintf( __( 'The &#8220;%s&#8221; plugin disables temporarily as required %s plugin is being upgraded.',
$this->get_text_domain() ),
$this->plugin_name, $nice_name, $nice_name );
$this->plugin_name, $nice_name, $nice_name ) );
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment