Skip to content
Snippets Groups Projects
Commit b9ad68ab authored by Grzegorz Rola's avatar Grzegorz Rola
Browse files

Feature/wp nonce

parent 167246cc
No related branches found
No related tags found
No related merge requests found
## [3.0.5] - 2019-09-20
### Fixed
- Fixed missing wp_create_nonce function
## [3.0.4] - 2019-09-20 ## [3.0.4] - 2019-09-20
### Fixed ### Fixed
- Fixed missing wp_nonce_url function - Fixed missing wp_nonce_url function
......
...@@ -312,7 +312,7 @@ if ( ! class_exists( 'WPDesk_Basic_Requirement_Checker' ) ) { ...@@ -312,7 +312,7 @@ if ( ! class_exists( 'WPDesk_Basic_Requirement_Checker' ) ) {
private function prepare_plugin_repository_install_url( $plugin_info ) { private function prepare_plugin_repository_install_url( $plugin_info ) {
$slug = basename( $plugin_info[ self::PLUGIN_INFO_KEY_NAME ] ); $slug = basename( $plugin_info[ self::PLUGIN_INFO_KEY_NAME ] );
$install_url = self_admin_url( 'update.php?action=install-plugin&plugin=' . $slug ); $install_url = self_admin_url( 'update.php?action=install-plugin&plugin=' . $slug );
if ( function_exists( 'wp_nonce_url' ) ) { if ( function_exists( 'wp_nonce_url' ) && function_exists( 'wp_create_nonce' ) ) {
$install_url = wp_nonce_url( $install_url, 'install-plugin_' . $slug ); $install_url = wp_nonce_url( $install_url, 'install-plugin_' . $slug );
} }
add_filter( 'plugins_api', function ( $api, $action, $args ) use ( $plugin_info, $slug ) { add_filter( 'plugins_api', function ( $api, $action, $args ) use ( $plugin_info, $slug ) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment