Skip to content
This repository has been archived by the owner on Aug 22, 2022. It is now read-only.

Commit

Permalink
Updated to 1.2.0 version
Browse files Browse the repository at this point in the history
  • Loading branch information
josantonius committed Jan 31, 2018
1 parent d0d35f2 commit 77cc945
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 24 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# CHANGELOG

## 1.2.0 - 2018-01-31

* Fixed bug in `WP_ Menu` Library: The private method `check_permissions()` was eliminated, it is unnecessary and affects the site's globally. WordPress's `add_menu_page()` and `add_submenu_page()` methods already display the page according to the user's capabilities.

## 1.1.9 - 2017-11-01

* Fixed error in options page when activating sensitive case.
Expand Down
2 changes: 1 addition & 1 deletion config/settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
return [

'slug' => dirname(dirname(plugin_basename( __FILE__))),
'version' => '1.1.9',
'version' => '1.2.0',
'minimum_wp_version' => '4.0',
'minimum_php_version' => '5.6',
];
20 changes: 0 additions & 20 deletions lib/vendor/josantonius/wp_menu/src/WP_Menu.php
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,6 @@ private static function _set($type, $slug) {

$data = self::$data[$type][$slug];

self::_checkPermissions($data['capability']);

do_action('wp_menu/pre_add_' . $type . '_page');

if ($type === 'menu') {
Expand Down Expand Up @@ -164,24 +162,6 @@ private static function _set($type, $slug) {
}
}

/**
* Validate permissions.
*
* @since 1.0.2
*
* @uses current_user_can() → specific capability
* @uses wp_die() → kill WordPress execution and show error
*/
private static function _checkPermissions($capability) {

if (!current_user_can($capability)) {

$message = __('You don\'t have permissions to access this page.');

wp_die($message);
}
}

/**
* Check if method exists.
*
Expand Down
12 changes: 10 additions & 2 deletions readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
Contributors: josantonius
Donate link: https://paypal.me/Josantonius
Tags: search-engine,wp-search-engine,highlight-words,highlight-phrases,highlight-paragraphs
Tested up to: 4.9
Stable tag: 1.1.9
Tested up to: 4.9.2
Stable tag: 1.2.0
Requires at least: 4.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Expand Down Expand Up @@ -87,6 +87,10 @@ Search Inside has full support for UTF-8 encoding and can search in any language

== Changelog ==

= 1.2.0 =

* Fixed bug in `WP_ Menu` Library: The private method `check_permissions()` was eliminated, it is unnecessary and affects the site's globally. WordPress's `add_menu_page()` and `add_submenu_page()` methods already display the page according to the user's capabilities.

= 1.1.9 =

* Fixed error in options page when activating sensitive case.
Expand Down Expand Up @@ -138,6 +142,10 @@ Changes in methods.

== Upgrade Notice ==

= 1.2.0 =

* Fixed bug in `WP_ Menu` Library: The private method `check_permissions()` was eliminated, it is unnecessary and affects the site's globally. WordPress's `add_menu_page()` and `add_submenu_page()` methods already display the page according to the user's capabilities.

= 1.1.9 =

* Fixed error in options page when activating sensitive case.
Expand Down
2 changes: 1 addition & 1 deletion search-inside.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* Plugin Name: Search Inside
* Plugin URI: https://github.com/Josantonius/Search-Inside.git
* Description: Easily search text within your pages or blog posts.
* Version: 1.1.9
* Version: 1.2.0
* Author: Josantonius
* Author URI: https://josantonius.com/
* License: GPL-2.0+
Expand Down

0 comments on commit 77cc945

Please sign in to comment.