Skip to content

Commit

Permalink
Added dokan pro update message.
Browse files Browse the repository at this point in the history
  • Loading branch information
Aunshon committed Nov 28, 2024
1 parent a8a0e53 commit 116c21b
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions includes/Admin/Notices/Manager.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ private function init_hooks() {
add_filter( 'dokan_admin_notices', [ $this, 'show_permalink_setting_notice' ] );
add_filter( 'dokan_admin_notices', [ $this, 'show_admin_logo_update_notice' ] );
add_action( 'wp_ajax_dismiss_dokan_admin_logo_update_notice', [ $this, 'dismiss_dokan_admin_logo_update_notice' ] );
add_filter( 'dokan_admin_notices', [ $this, 'show_admin_commission_notice' ] );
add_filter( 'dokan_admin_notices', [ $this, 'show_admin_plugin_update_notice' ] );
}

/**
Expand Down Expand Up @@ -191,7 +191,16 @@ private function dismiss_notice( string $option_name ) {
wp_send_json_success();
}

public function show_admin_commission_notice( $notices ) {
/**
* Show admin notice if dokan lite is updated to v3.14.0 and dokan pro is not updated to minimum v3.14.0.
*
* @since DOKAN_SINCE
*
* @param $notices
*
* @return mixed
*/
public function show_admin_plugin_update_notice( $notices ) {
if (
version_compare( DOKAN_PLUGIN_VERSION, '3.14.0', '>=' ) &&
defined( 'DOKAN_PRO_PLUGIN_VERSION' ) &&
Expand Down

0 comments on commit 116c21b

Please sign in to comment.